aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-06-03 16:08:08 -0700
committerMario Vavti <mario@mariovavti.com>2017-06-07 09:34:45 +0200
commit01b541d8b04e93de8f90c420610c656f6d3e2fb0 (patch)
tree4f51e60e3137ba1f2e6c6acb752210bfd4f6f22b /Zotlabs
parent928fce875e712614e985ae2eaf8cc4f47615fe27 (diff)
downloadvolse-hubzilla-01b541d8b04e93de8f90c420610c656f6d3e2fb0.tar.gz
volse-hubzilla-01b541d8b04e93de8f90c420610c656f6d3e2fb0.tar.bz2
volse-hubzilla-01b541d8b04e93de8f90c420610c656f6d3e2fb0.zip
oembed: ensure that width and height are returned as type int and not float
Diffstat (limited to 'Zotlabs')
-rw-r--r--Zotlabs/Module/Oep.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/Zotlabs/Module/Oep.php b/Zotlabs/Module/Oep.php
index dc0547a42..9c05f5e3f 100644
--- a/Zotlabs/Module/Oep.php
+++ b/Zotlabs/Module/Oep.php
@@ -108,7 +108,7 @@ class Oep extends \Zotlabs\Web\Controller {
$ret['type'] = 'rich';
$w = (($maxwidth) ? $maxwidth : 640);
- $h = (($maxheight) ? $maxheight : $w * 2 / 3);
+ $h = (($maxheight) ? $maxheight : intval($w * 2 / 3));
$ret['html'] = '<div style="width: ' . $w . '; height: ' . $h . '; font-family: sans-serif,arial,freesans;" >' . $o . '</div>';
@@ -167,7 +167,7 @@ class Oep extends \Zotlabs\Web\Controller {
$ret['type'] = 'rich';
$w = (($maxwidth) ? $maxwidth : 640);
- $h = (($maxheight) ? $maxheight : $w * 2 / 3);
+ $h = (($maxheight) ? $maxheight : intval($w * 2 / 3));
$ret['html'] = '<div style="width: ' . $w . '; height: ' . $h . '; font-family: sans-serif,arial,freesans;" >' . $o . '</div>';