changeset 204:e6c2048e2c94

Added ability to make simple links to child pages.
author Ludovic Chabant <ludovic@chabant.com>
date Thu, 13 Feb 2014 23:55:41 -0800
parents e845ff2b4bd8
children 719bcebefd68
files wikked/utils.py
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/wikked/utils.py	Wed Feb 12 15:24:29 2014 -0800
+++ b/wikked/utils.py	Thu Feb 13 23:55:41 2014 -0800
@@ -54,6 +54,10 @@
     if url.startswith('/'):
         # Absolute page URL.
         abs_url = url
+    elif url.startswith('./'):
+        # URL wants to be relative to the base url's name, instead
+        # of its directory.
+        abs_url = base_url + url[1:]
     else:
         # Relative page URL. Let's normalize all `..` in it,
         # which could also replace forward slashes by backslashes