-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[3.x] com_wrapper. Add HTML5 mode without B\C break. #19985
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
09ebbf1
0ff3eb2
a04892c
f6938c2
47a52d6
a365c60
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -9,8 +9,27 @@ | |
|
|
||
| defined('_JEXEC') or die; | ||
|
|
||
| JHtml::_('script', 'com_wrapper/iframe-height.min.js', array('version' => 'auto', 'relative' => true)); | ||
| if ($this->params->get('height_auto', 0)) | ||
| { | ||
| JHtml::_('script', 'com_wrapper/iframe-height.min.js', array('version' => 'auto', 'relative' => true)); | ||
| } | ||
|
|
||
| $isHtml5 = $this->params->get('mode', 'legacy') === 'html5'; | ||
| $width = $this->escape($this->params->get('width', '100%')); | ||
| $height = $this->escape($this->params->get('height', '500')) . ($isHtml5 ? 'px' : ''); | ||
| $scrolling = $this->escape($this->params->get('scrolling', 'auto')); | ||
| $frameborder = $this->escape($this->params->get('frameborder', 1)); | ||
|
|
||
| if ($isHtml5) | ||
| { | ||
|
|
||
|
||
| if ($scrolling !== 'auto') | ||
| { | ||
| $scrolling = ($scrolling === 'no' ? 'hidden' : 'scroll'); | ||
|
||
| } | ||
|
|
||
| $frameborder = (!$frameborder ? 'none' : $frameborder . 'px solid #000'); | ||
|
||
| } | ||
| ?> | ||
| <div class="contentpane<?php echo $this->pageclass_sfx; ?>"> | ||
| <?php if ($this->params->get('show_page_heading')) : ?> | ||
|
|
@@ -28,10 +47,17 @@ | |
| id="blockrandom" | ||
| name="iframe" | ||
| src="<?php echo $this->escape($this->wrapper->url); ?>" | ||
| width="<?php echo $this->escape($this->params->get('width')); ?>" | ||
| height="<?php echo $this->escape($this->params->get('height')); ?>" | ||
| scrolling="<?php echo $this->escape($this->params->get('scrolling')); ?>" | ||
| frameborder="<?php echo $this->escape($this->params->get('frameborder', 1)); ?>" | ||
| <?php if ($isHtml5) : ?> | ||
| style="width: <?php echo $width; ?>; | ||
| height: <?php echo $height; ?>; | ||
| overflow: <?php echo $scrolling; ?>; | ||
| border: <?php echo $frameborder; ?>" | ||
| <?php else : ?> | ||
| width="<?php echo $width; ?>" | ||
| height="<?php echo $height; ?>" | ||
| scrolling="<?php echo $scrolling; ?>" | ||
| frameborder="<?php echo $frameborder; ?>" | ||
| <?php endif; ?> | ||
| <?php if ($this->escape($this->params->get('page_heading'))) : ?> | ||
| title="<?php echo $this->escape($this->params->get('page_heading')); ?>" | ||
| <?php else : ?> | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change to
COM_WRAPPER_FIELD_MODE_DESC