mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 22:25:55 +00:00
Handle potentially-relative base element when getting favicon.
The base element's "href" attribute is not required to be absolute, so rewrite relative to the site URL if it is relative. See: * https://www.w3.org/TR/html51/document-metadata.html#the-base-element * https://html.spec.whatwg.org/multipage/semantics.html#the-base-element
This commit is contained in:
@@ -577,7 +577,7 @@
|
|||||||
|
|
||||||
$base = $xpath->query('/html/head/base');
|
$base = $xpath->query('/html/head/base');
|
||||||
foreach ($base as $b) {
|
foreach ($base as $b) {
|
||||||
$url = $b->getAttribute("href");
|
$url = rewrite_relative_url($url, $b->getAttribute("href"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user