r53845 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r53844‎ | r53845 | r53846 >
Date:00:07, 28 July 2009
Author:simetrical
Status:ok
Tags:
Comment:
Comment on limitations of wfExpandUrl
Modified paths:
  • /trunk/phase3/includes/GlobalFunctions.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/GlobalFunctions.php
@@ -1303,8 +1303,12 @@
13041304 }
13051305
13061306 /**
1307 - * Expand a potentially local URL to a fully-qualified URL.
1308 - * Assumes $wgServer is correct. :)
 1307+ * Expand a potentially local URL to a fully-qualified URL. Assumes $wgServer
 1308+ * is correct. Also doesn't handle any type of relative URL except one
 1309+ * starting with a single "/": this won't work with current-path-relative URLs
 1310+ * like "subdir/foo.html", protocol-relative URLs like
 1311+ * "//en.wikipedia.org/wiki/", etc. TODO: improve this!
 1312+ *
13091313 * @param $url String: either fully-qualified or a local path + query
13101314 * @return string Fully-qualified URL
13111315 */

Status & tagging log