From: Andrew Dolgov Date: Wed, 14 Feb 2007 16:17:31 +0000 (+0100) Subject: correctly import feed://... urls X-Git-Tag: 1.2.8~5 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=b3dfe8bae76190ab58758e0d3ba1f7fe28cf847a;p=tt-rss.git correctly import feed://... urls --- diff --git a/functions.php b/functions.php index 1eb3ef2f..df2ec588 100644 --- a/functions.php +++ b/functions.php @@ -1938,8 +1938,14 @@ function subscribe_to_feed($link, $feed_link, $cat_id = 0) { + # check for feed:http://url $feed_link = trim(preg_replace("/^feed:/", "", $feed_link)); + # check for feed://URL + if (strstr($feed_link, "//") == 0) { + $feed_link = "http:$feed_link"; + } + if ($feed_link == "") return; if ($cat_id == "0" || !$cat_id) {