diff options
author | Mario Vavti <mario@mariovavti.com> | 2016-12-23 10:09:46 +0100 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2016-12-23 10:09:46 +0100 |
commit | 3b9b03cf86979b28e7fa249133176bed84b0105c (patch) | |
tree | 336dc8b8b9627e7f4a93e5c35fe3e98555274616 /include/oembed.php | |
parent | 2e5a993f880d619aedf3693927e7b3e164fbfcc0 (diff) | |
parent | ef39c1e94b5149a3019d417d08dc7c16c8aef9c1 (diff) | |
download | volse-hubzilla-3b9b03cf86979b28e7fa249133176bed84b0105c.tar.gz volse-hubzilla-3b9b03cf86979b28e7fa249133176bed84b0105c.tar.bz2 volse-hubzilla-3b9b03cf86979b28e7fa249133176bed84b0105c.zip |
Merge branch '2.0RC'
Diffstat (limited to 'include/oembed.php')
-rwxr-xr-x | include/oembed.php | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/include/oembed.php b/include/oembed.php index 1780e7046..eb7b76437 100755 --- a/include/oembed.php +++ b/include/oembed.php @@ -137,10 +137,6 @@ function oembed_fetch_url($embedurl){ if($action !== 'block') { $txt = Zlib\Cache::get('[' . App::$videowidth . '] ' . $embedurl); - - if(strstr($txt,'youtu') && strstr(z_root(),'https:')) { - $txt = str_replace('http:','https:',$txt); - } } if(is_null($txt)) { @@ -272,13 +268,7 @@ function oembed_format_object($j){ $th=120; $tw = $th*$tr; $tpl=get_markup_template('oembed_video.tpl'); - if(strstr($embedurl,'youtu') && strstr(z_root(),'https:')) { - $embedurl = str_replace('http:','https:',$embedurl); - $j['thumbnail_url'] = str_replace('http:','https:', $j['thumbnail_url']); - $jhtml = str_replace('http:','https:', $jhtml); - $j['html'] = str_replace('http:','https:', $j['html']); - - } + $ret.=replace_macros($tpl, array( '$baseurl' => z_root(), '$embedurl'=>$embedurl, @@ -348,7 +338,7 @@ function oembed_iframe($src,$width,$height) { // Make sure any children are sandboxed within their own iframe. - return '<iframe ' . $scroll . 'height="' . $height . '" width="' . $width . '" src="' . $s . '" frameborder="no" >' + return '<iframe ' . $scroll . 'height="' . $height . '" width="' . $width . '" src="' . $s . '" allowfullscreen frameborder="no" >' . t('Embedded content') . '</iframe>'; } |