summaryrefslogtreecommitdiffstats
path: root/flatpages/views.py
diff options
context:
space:
mode:
Diffstat (limited to 'flatpages/views.py')
-rw-r--r--flatpages/views.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/flatpages/views.py b/flatpages/views.py
index 8222421..43576b9 100644
--- a/flatpages/views.py
+++ b/flatpages/views.py
@@ -89,10 +89,10 @@ def flatpage(request, path):
menumatch = re.match(rb'(.*)<ul id="links">', body, re.DOTALL + re.IGNORECASE)
if menumatch:
has_menu = True
- #body, = menumatch.groups()
- if re.search(rb"iso-8859-1", html):
- body = str(body, "iso-8859-1")
- body.strip
+ body, = menumatch.groups()
+# if re.search(rb"iso-8859-1", html):
+# body = str(body, "iso-8859-1")
+# body.strip
return render(request, 'flatpage.html', {'editable': editable, 'path': path, 'title': title, 'body': body, 'homepage': (path == "index.htm"), 'has_menu': has_menu})
else:
return HttpResponse(o.read(), content_type=getmimetype(path))
@@ -137,8 +137,8 @@ def editflatpage(request, path):
linksmatch = re.match(r'(.*)(<ul\s+id="links">.*)', body, re.DOTALL + re.IGNORECASE)
if linksmatch:
body, links = linksmatch.groups()
- if re.search(r"iso-8859-1", html):
- body = str(body, "iso-8859-1")
+# if re.search(r"iso-8859-1", html):
+# body = str(body, "iso-8859-1")
else:
return HttpResponse("Page could not be split into header and body")
except IOError: