From f9052d35acb3379b47fd18649b6a37c660ea1bb5 Mon Sep 17 00:00:00 2001 From: fluffy Date: Sun, 22 Jul 2012 09:26:29 -0700 Subject: [PATCH] Support protocol-relative URLs --- include/functions.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/functions.php b/include/functions.php index a3de2461d..394f540c9 100644 --- a/include/functions.php +++ b/include/functions.php @@ -4800,6 +4800,9 @@ return $rel_url; } else if (strpos($rel_url, "://") !== false) { return $rel_url; + } else if (strpos($rel_url, "//") === 0) { + # protocol-relative URL (rare but they exist) + return $rel_url; } else if (strpos($rel_url, "/") === 0) { $parts = parse_url($url);