Browse Source

Merge branch 'relative_html_base' of wn/tt-rss into master

fox 2 years ago
parent
commit
3b8d9bc6ff
1 changed files with 2 additions and 2 deletions
  1. 2 2
      include/functions.php

+ 2 - 2
include/functions.php

@@ -575,9 +575,9 @@
 			$doc->loadHTML($html);
 			$xpath = new DOMXPath($doc);
 
-			$base = $xpath->query('/html/head/base');
+			$base = $xpath->query('/html/head/base[@href]');
 			foreach ($base as $b) {
-				$url = $b->getAttribute("href");
+				$url = rewrite_relative_url($url, $b->getAttribute("href"));
 				break;
 			}