From 03e644ec6293494f195063ed6c3af99d8b6978d1 Mon Sep 17 00:00:00 2001 From: Dan Date: Fri, 21 Aug 2015 11:26:48 -0400 Subject: [PATCH] Add support for width and height to embedded photos Noticed that "from the web" images don't respect the width and height settings, this fixes that. --- oembed/Oembed.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/oembed/Oembed.php b/oembed/Oembed.php index da94dccf9..0c8c55cc6 100644 --- a/oembed/Oembed.php +++ b/oembed/Oembed.php @@ -238,7 +238,14 @@ class Oembed_Result extends ViewableData { if(isset($options['class'])) { $this->extraClass = $options['class']; } - + if($options) { + if(isset($options['width'])) { + $this->Width = $options['width']; + } + if(isset($options['height'])) { + $this->Height = $options['height']; + } + } parent::__construct(); }