diff options
author | marijus <mario@mariovavti.com> | 2014-10-08 15:09:54 +0200 |
---|---|---|
committer | marijus <mario@mariovavti.com> | 2014-10-08 15:09:54 +0200 |
commit | 9a1c3f10b2ea10e69fe1d293ce1ae25bdcd37a8a (patch) | |
tree | 13bdeb80011b80c169d1b2a4db768f1d9f0758ed /include | |
parent | 0dcbebba771da7a883c4305059dfbc9e5f5111bd (diff) | |
parent | 1fc3138c37564f44ea028c5fa8e69c718d08f363 (diff) | |
download | volse-hubzilla-9a1c3f10b2ea10e69fe1d293ce1ae25bdcd37a8a.tar.gz volse-hubzilla-9a1c3f10b2ea10e69fe1d293ce1ae25bdcd37a8a.tar.bz2 volse-hubzilla-9a1c3f10b2ea10e69fe1d293ce1ae25bdcd37a8a.zip |
Merge branch 'master' of https://github.com/friendica/red
Diffstat (limited to 'include')
-rwxr-xr-x | include/oembed.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/oembed.php b/include/oembed.php index de3a6edc8..8ce0fee96 100755 --- a/include/oembed.php +++ b/include/oembed.php @@ -56,6 +56,15 @@ function oembed_fetch_url($embedurl){ $txt = $x['body']; break; } + // soundcloud is now using text/json+oembed instead of application/json+oembed, + // others may be also + $entries = $xpath->query("//link[@type='text/json+oembed']"); + foreach($entries as $e){ + $href = $e->getAttributeNode("href")->nodeValue; + $x = z_fetch_url($href . '&maxwidth=' . $a->videowidth); + $txt = $x['body']; + break; + } } } } |