aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-06-03 16:08:08 -0700
committerzotlabs <mike@macgirvin.com>2017-06-03 16:08:08 -0700
commit43914852e5214421a0c5c2256e61344617c4fd22 (patch)
tree184ef946883bc0db10b31aa8c500a1a463ad7106 /Zotlabs
parentc7f097ec849b05065f12246d2e647ead03f9592f (diff)
downloadvolse-hubzilla-43914852e5214421a0c5c2256e61344617c4fd22.tar.gz
volse-hubzilla-43914852e5214421a0c5c2256e61344617c4fd22.tar.bz2
volse-hubzilla-43914852e5214421a0c5c2256e61344617c4fd22.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>';