mirror of
https://github.com/joomla-extensions/weblinks.git
synced 2024-10-31 19:02:30 +00:00
Merge pull request #11 from chmst/fix-changed-float-params
Float params have changed - fix layouts
This commit is contained in:
commit
72c7f9b072
@ -28,7 +28,6 @@ $canEdit = $user->authorise('core.edit', 'com_weblinks.category.' . $this->ca
|
|||||||
$canEditOwn = $user->authorise('core.edit.own', 'com_weblinks.category.' . $this->category->id);
|
$canEditOwn = $user->authorise('core.edit.own', 'com_weblinks.category.' . $this->category->id);
|
||||||
$canCreate = $user->authorise('core.create', 'com_weblinks.category.' . $this->category->id);
|
$canCreate = $user->authorise('core.create', 'com_weblinks.category.' . $this->category->id);
|
||||||
|
|
||||||
$n = count($this->items);
|
|
||||||
$listOrder = $this->escape($this->state->get('list.ordering'));
|
$listOrder = $this->escape($this->state->get('list.ordering'));
|
||||||
$listDirn = $this->escape($this->state->get('list.direction'));
|
$listDirn = $this->escape($this->state->get('list.direction'));
|
||||||
?>
|
?>
|
||||||
@ -156,13 +155,16 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php if (($this->params->get('show_link_description')) && ($item->description != '')) : ?>
|
<?php if (($this->params->get('show_link_description')) && ($item->description != '')) : ?>
|
||||||
<div class="mt-2 mb-2">
|
<div class="mt-2 mb-2">
|
||||||
<?php $images = json_decode($item->images); ?>
|
<?php $images = json_decode($item->images); ?>
|
||||||
<?php if (!empty($images->image_first)) : ?>
|
<?php if (!empty($images->image_first)) : ?>
|
||||||
<?php $imgfloat = (empty($images->float_first)) ? $this->params->get('float_first') : $images->float_first; ?>
|
<?php $imgFloat = '' ;?>
|
||||||
|
<?php if (!empty($images->float_first)) : ?>
|
||||||
|
<?php $imgFloat = $images->float_first == 'right' ? 'float-end' : 'float-start'; ?>
|
||||||
|
<?php endif; ?>
|
||||||
<?php $img = HTMLHelper::cleanImageURL($images->image_first); ?>
|
<?php $img = HTMLHelper::cleanImageURL($images->image_first); ?>
|
||||||
<?php $alt = empty($images->image_first_alt) && empty($images->image_first_alt_empty)
|
<?php $alt = empty($images->image_first_alt) && empty($images->image_first_alt_empty)
|
||||||
? ''
|
? ''
|
||||||
: 'alt="' . htmlspecialchars($images->image_first_alt, ENT_COMPAT, 'UTF-8') . '"'; ?>
|
: 'alt="' . htmlspecialchars($images->image_first_alt, ENT_COMPAT, 'UTF-8') . '"'; ?>
|
||||||
<figure class="item-image">
|
<figure class="item-image <?php echo $imgFloat; ?>">
|
||||||
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
||||||
<?php echo $alt; ?> itemprop="thumbnail" />
|
<?php echo $alt; ?> itemprop="thumbnail" />
|
||||||
<?php if (!empty($images->image_first_caption)) : ?>
|
<?php if (!empty($images->image_first_caption)) : ?>
|
||||||
@ -172,12 +174,15 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php if (!empty($images->image_second)) : ?>
|
<?php if (!empty($images->image_second)) : ?>
|
||||||
<?php $imgfloat = (empty($images->float_second)) ? $this->params->get('float_second') : $images->float_second; ?>
|
<?php $imgFloat = ''; ?>
|
||||||
|
<?php if (!empty($images->float_second)) : ?>
|
||||||
|
<?php $imgFloat = $images->float_second == 'right' ? 'float-end' : 'float-start'; ?>
|
||||||
|
<?php endif; ?>
|
||||||
<?php $img = HTMLHelper::cleanImageURL($images->image_second); ?>
|
<?php $img = HTMLHelper::cleanImageURL($images->image_second); ?>
|
||||||
<?php $alt = empty($images->image_second_alt) && empty($images->image_second_alt_empty)
|
<?php $alt = empty($images->image_second_alt) && empty($images->image_second_alt_empty)
|
||||||
? ''
|
? ''
|
||||||
: 'alt="' . htmlspecialchars($images->image_second_alt, ENT_COMPAT, 'UTF-8') . '"'; ?>
|
: 'alt="' . htmlspecialchars($images->image_second_alt, ENT_COMPAT, 'UTF-8') . '"'; ?>
|
||||||
<figure class="item-image">
|
<figure class="item-image <?php echo $imgFloat; ?>">
|
||||||
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
||||||
<?php echo $alt; ?> itemprop="thumbnail" />
|
<?php echo $alt; ?> itemprop="thumbnail" />
|
||||||
<?php if (!empty($images->image_second_caption)) : ?>
|
<?php if (!empty($images->image_second_caption)) : ?>
|
||||||
|
@ -40,60 +40,70 @@ if (!$canEdit)
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php // Content is generated by content plugin event "onContentAfterTitle" ?>
|
<?php // Content is generated by content plugin event "onContentAfterTitle" ?>
|
||||||
<?php echo $this->item->event->afterDisplayTitle; ?>
|
<?php echo $this->item->event->afterDisplayTitle; ?>
|
||||||
|
|
||||||
<?php // Content is generated by content plugin event "onContentBeforeDisplay" ?>
|
<?php // Content is generated by content plugin event "onContentBeforeDisplay" ?>
|
||||||
<?php echo $this->item->event->beforeDisplayContent; ?>
|
<?php echo $this->item->event->beforeDisplayContent; ?>
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
<div itemprop="articleBody">
|
||||||
<a href="<?php echo $weblinkUrl; ?>" target="_blank" itemprop="url">
|
<div class="p-3">
|
||||||
<?php echo $weblinkUrl; ?>
|
<a href="<?php echo $weblinkUrl; ?>" target="_blank" itemprop="url">
|
||||||
</a>
|
<?php echo $weblinkUrl; ?>
|
||||||
|
</a>
|
||||||
<?php if (($this->params->get('show_link_description')) && ($this->item->description != '')) : ?>
|
</div>
|
||||||
<div class="mt-2 mb-2">
|
|
||||||
<?php $images = json_decode($this->item->images); ?>
|
|
||||||
<?php if (!empty($images->image_first)) : ?>
|
|
||||||
<?php $imgFloat = '';
|
|
||||||
if (!empty($images->float_first)) :
|
|
||||||
$imgFloat = $images->float_first == 'right' ? 'float-end' : 'float-start';
|
|
||||||
endif;
|
|
||||||
$img = HTMLHelper::cleanImageURL($images->image_first);
|
|
||||||
$alt = empty($images->image_first_alt) && empty($images->image_first_alt_empty)
|
|
||||||
? ''
|
|
||||||
: 'alt="' . htmlspecialchars($images->image_first_alt, ENT_COMPAT, 'UTF-8') . '"';
|
|
||||||
?>
|
|
||||||
<figure class="item-image <?php echo $imgFloat; ?>">
|
|
||||||
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
|
||||||
<?php echo $alt; ?> itemprop="thumbnail" />
|
|
||||||
<?php if (!empty($images->image_first_caption)) : ?>
|
|
||||||
<figcaption class="caption"><?php echo htmlspecialchars($images->image_first_caption, ENT_COMPAT, 'UTF-8'); ?></figcaption>
|
|
||||||
<?php endif; ?>
|
|
||||||
</figure>
|
|
||||||
<?php endif; ?>
|
|
||||||
|
|
||||||
<?php if (!empty($images->image_second)) : ?>
|
|
||||||
<?php $imgFloat = '';
|
|
||||||
if (!empty($images->float_second)) :
|
|
||||||
$imgFloat = $images->float_second == 'right' ? 'float-end' : 'float-start';
|
|
||||||
endif;
|
|
||||||
$img = HTMLHelper::cleanImageURL($images->image_second);
|
|
||||||
$alt = empty($images->image_first_alt) && empty($images->image_second_alt_empty)
|
|
||||||
? ''
|
|
||||||
: 'alt="' . htmlspecialchars($images->image_second_alt, ENT_COMPAT, 'UTF-8') . '"';
|
|
||||||
?>
|
|
||||||
<figure class="item-image <?php echo $imgFloat; ?>">
|
|
||||||
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
|
||||||
<?php echo $alt; ?> itemprop="thumbnail" />
|
|
||||||
<?php if (!empty($images->image_second_caption)) : ?>
|
|
||||||
<figcaption class="caption"><?php echo htmlspecialchars($images->image_second_caption, ENT_COMPAT, 'UTF-8'); ?></figcaption>
|
|
||||||
<?php endif; ?>
|
|
||||||
</figure>
|
|
||||||
<?php endif; ?>
|
|
||||||
|
|
||||||
<?php echo $this->item->description; ?>
|
|
||||||
|
|
||||||
|
<?php if ($this->params->get('show_tags', 1) && !empty($this->item->tags->itemTags)) : ?>
|
||||||
|
<div class="p-2">
|
||||||
|
<?php echo LayoutHelper::render('joomla.content.tags', $this->item->tags->itemTags); ?>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<div class="p-3">
|
||||||
|
<?php $images = json_decode($this->item->images); ?>
|
||||||
|
<?php if (!empty($images->image_first)) : ?>
|
||||||
|
<?php $imgFloat = '' ;?>
|
||||||
|
<?php if (!empty($images->float_first)) : ?>
|
||||||
|
<?php $imgFloat = $images->float_first == 'right' ? 'float-end' : 'float-start'; ?>
|
||||||
|
<?php endif; ?>
|
||||||
|
<?php $img = HTMLHelper::cleanImageURL($images->image_first); ?>
|
||||||
|
<?php $alt = empty($images->image_first_alt) && empty($images->image_first_alt_empty)
|
||||||
|
? ''
|
||||||
|
: 'alt="' . htmlspecialchars($images->image_first_alt, ENT_COMPAT, 'UTF-8') . '"'; ?>
|
||||||
|
<figure class="item-image <?php echo $imgFloat; ?>">
|
||||||
|
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
||||||
|
<?php echo $alt; ?> itemprop="thumbnail" />
|
||||||
|
<?php if (!empty($images->image_first_caption)) : ?>
|
||||||
|
<figcaption class="caption"><?php echo htmlspecialchars($images->image_first_caption, ENT_COMPAT, 'UTF-8'); ?></figcaption>
|
||||||
|
<?php endif; ?>
|
||||||
|
</figure>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<?php if (!empty($images->image_second)) : ?>
|
||||||
|
<?php $imgFloat = ''; ?>
|
||||||
|
<?php if (!empty($images->float_second)) : ?>
|
||||||
|
<?php $imgFloat = $images->float_second == 'right' ? 'float-end' : 'float-start'; ?>
|
||||||
|
<?php endif; ?>
|
||||||
|
<?php $img = HTMLHelper::cleanImageURL($images->image_second); ?>
|
||||||
|
<?php $alt = empty($images->image_second_alt) && empty($images->image_second_alt_empty)
|
||||||
|
? ''
|
||||||
|
: 'alt="' . htmlspecialchars($images->image_second_alt, ENT_COMPAT, 'UTF-8') . '"'; ?>
|
||||||
|
<figure class="item-image <?php echo $imgFloat; ?>">
|
||||||
|
<img src="<?php echo htmlspecialchars($img->url, ENT_COMPAT, 'UTF-8'); ?>"
|
||||||
|
<?php echo $alt; ?> itemprop="thumbnail" />
|
||||||
|
<?php if (!empty($images->image_second_caption)) : ?>
|
||||||
|
<figcaption class="caption"><?php echo htmlspecialchars($images->image_second_caption, ENT_COMPAT, 'UTF-8'); ?></figcaption>
|
||||||
|
<?php endif; ?>
|
||||||
|
</figure>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<?php if (!empty($this->item->description)) : ?>
|
||||||
|
<?php echo $this->item->description; ?>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<?php // Content is generated by content plugin event "onContentAfterDisplay" ?>
|
<?php // Content is generated by content plugin event "onContentAfterDisplay" ?>
|
||||||
<?php echo $this->item->event->afterDisplayContent; ?>
|
<?php echo $this->item->event->afterDisplayContent; ?>
|
||||||
|
Loading…
Reference in New Issue
Block a user