2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2025-12-16 19:27:07 +00:00

The editing system was accidentally deleting customised sidebar menus. This will stop the happening

This commit is contained in:
Martin Green
2022-06-23 20:03:05 +01:00
parent 2f42f488ab
commit 97a9f2aae6

View File

@@ -306,11 +306,10 @@ def editexpopage(request, path):
if m: if m:
filefound = True filefound = True
preheader, headerargs, head, postheader, bodyargs, body, postbody = m.groups() preheader, headerargs, head, postheader, bodyargs, body, postbody = m.groups()
linksmatch = re.match(r'(.*)(<ul\s+id="links">.*)', body, re.DOTALL + re.IGNORECASE) # linksmatch = re.match(r'(.*)(<ul\s+id="links">.*)', body, re.DOTALL + re.IGNORECASE)
if linksmatch: # if linksmatch:
body, links = linksmatch.groups() # body, links = linksmatch.groups()
# if re.search(r"iso-8859-1", html):
# body = str(body, "iso-8859-1")
else: else:
return HttpResponse(default_head + html + '<h3>HTML Parsing failure:<br>Page could not be parsed into header and body:<br>failure detected in expowebpage in views.expo.py</h3> Please edit this <var>:expoweb:</var> page to be in the expected full HTML format .</body>' ) return HttpResponse(default_head + html + '<h3>HTML Parsing failure:<br>Page could not be parsed into header and body:<br>failure detected in expowebpage in views.expo.py</h3> Please edit this <var>:expoweb:</var> page to be in the expected full HTML format .</body>' )
except IOError: except IOError: