add support for video[@src] in media cache
it's a valid alternative to a source[@src] child element: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video
This commit is contained in:
parent
cdde23b4dc
commit
ec1b0befc7
|
@ -89,7 +89,7 @@ class DiskCache {
|
|||
$xpath = new DOMXPath($doc);
|
||||
$cache = new DiskCache("images");
|
||||
|
||||
$entries = $xpath->query('(//img[@src]|//picture/source[@src]|//video[@poster]|//video/source[@src]|//audio/source[@src])');
|
||||
$entries = $xpath->query('(//img[@src]|//picture/source[@src]|//video[@poster]|//video[@src]|//video/source[@src]|//audio/source[@src])');
|
||||
|
||||
$need_saving = false;
|
||||
|
||||
|
|
|
@ -1229,7 +1229,7 @@ class RSSUtils {
|
|||
if ($doc->loadHTML($html)) {
|
||||
$xpath = new DOMXPath($doc);
|
||||
|
||||
$entries = $xpath->query('(//img[@src])|(//video/source[@src])|(//audio/source[@src])|(//video[@poster])');
|
||||
$entries = $xpath->query('(//img[@src])|(//video/source[@src])|(//audio/source[@src])|(//video[@poster])|(//video[@src])');
|
||||
|
||||
foreach ($entries as $entry) {
|
||||
foreach (array('src', 'poster') as $attr) {
|
||||
|
|
Loading…
Reference in New Issue