mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2025-12-14 23:17:05 +00:00
Allow pages to be rendered when the body tag has attributes. Put an edit link on the homepage.
This commit is contained in:
@@ -56,7 +56,7 @@ def flatpage(request, path):
|
||||
if path.endswith(".htm") or path.endswith(".html"):
|
||||
html = o.read()
|
||||
|
||||
m = re.search(r"<head>(.*)</head>.*<body>(.*)</body>", html, re.DOTALL)
|
||||
m = re.search(r"<head>(.*)</head>.*<body[^>]*>(.*)</body>", html, re.DOTALL)
|
||||
if m:
|
||||
head, body = m.groups()
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user