1.1 --- a/scripts/redirect.py Sun Nov 03 14:52:17 2013 +0100
1.2 +++ b/scripts/redirect.py Sun Nov 03 19:40:56 2013 +0100
1.3 @@ -16,6 +16,7 @@
1.4 # An empty string means that the wiki is anchored at the site root.
1.5
1.6 URL_PREFIX = ""
1.7 +EXPORT_SCRIPT = "/export.py"
1.8
1.9 # See the scripts/tiny.py program for similar code in a stand-alone program.
1.10
1.11 @@ -79,7 +80,7 @@
1.12 if pageid is None:
1.13 fail(pageid)
1.14
1.15 - export = script.endswith("/pages/doexportpage.action") and args.get("type", [""])[0] == "TYPE_PDF"
1.16 + export = (script.endswith(EXPORT_SCRIPT) or script.endswith("/pages/doexportpage.action")) and args.get("type", [""])[0] == "TYPE_PDF"
1.17
1.18 f = open(MAPPING_ID_TO_PAGE)
1.19 try: