doesn't only affect preview
authorJoey Hess <joey@kitenet.net>
Wed, 5 Jan 2011 17:19:26 +0000 (13:19 -0400)
committerJoey Hess <joey@kitenet.net>
Wed, 5 Jan 2011 17:19:26 +0000 (13:19 -0400)
doc/bugs/preview_base_url_should_be_absolute.mdwn

index 86575eed97d8e3353451692197936941e0cea4e5..5391d39d6e045194013559e2af286f9644a34945 100644 (file)
@@ -24,3 +24,16 @@ git|http://git.oblomov.eu/ikiwiki]].
 >> `CGI::url` uses `REQUEST_URI`. So it could be used, but I don't see
 >> how to get from the `CGI::url` to an url to the page that is being
 >> edited. --[[Joey]]
+>>> (The right rune seems to be: `URI->new_abs(urlto($params{page}), $cgi->url))` --[[Joey]] 
+
+---
+
+Update: This bug is worse than it first appeared, and does not only affect
+previewing. The cgi always has a `<base>` url, and it's always relative,
+and that can break various links etc. For example, when the 404 plugin
+displays a missing page, it has a Recentchanges link, which would be broken
+if the cgi was in an unusual place.
+
+`misctemplate` needs to *always* set an absolute baseurl. Which is a problem,
+since `misctemplate` is not currently passed a cgi object from which to
+construct one. --[[Joey]]