links = ['<a href="#%s">%s</a>' % (ch, ch) for ch in 'abcdefghijklmnopqrstuvwxyz']
return '<p style="text-align: center">' + ' | '.join(links) + '</p>'
-def page_list(dirname=None, re=None):
- if re is None:
+def page_list(dirname=None, search_re=None):
+ if search_re is None:
# FIXME: WikiWord is too restrictive now!
- re = re.compile(r"^\b((([A-Z][a-z0-9]+){2,}/)*([A-Z][a-z0-9]+){2,})\b$")
- return sorted(filter(re.match, os.listdir(dirname or config_get('data_dir', 'data'))))
+ search_re = re.compile(r"^\b((([A-Z][a-z0-9]+){2,}/)*([A-Z][a-z0-9]+){2,})\b$")
+ return sorted(filter(search_re.match, os.listdir(dirname or config_get('data_dir', 'data'))))
def send_footer(mod_string=None):
if config_get('debug_cgi', False):