Don't rewrite the single page URL in single-page.html.
authorCameron McCormack <cam@mcc.id.au>
Thu, 28 Mar 2013 12:44:38 +1100
changeset 68 557b9e931bcb
parent 67 6704e4afa639
child 69 63ff451f26c5
Don't rewrite the single page URL in single-page.html.
publish/publish.js
--- a/publish/publish.js	Thu Mar 28 11:21:11 2013 +1100
+++ b/publish/publish.js	Thu Mar 28 12:44:38 2013 +1100
@@ -158,7 +158,7 @@
               n.setAttribute('href', '#' + page + '-' + href.substring(1));
             } else if (href.match(/^([^\/]+)\.html#(.*)$/)) {
               n.setAttribute('href', '#' + RegExp.$1 + '-' + RegExp.$2);
-            } else if (href.match(/^([^\/]+)\.html$/)) {
+            } else if (href.match(/^([^\/]+)\.html$/) && RegExp.$1 != 'single-page') {
               n.setAttribute('href', '#chapter-' + RegExp.$1);
             }
           }