mirror of
https://github.com/joomla-extensions/weblinks.git
synced 2024-09-20 17:19:07 +00:00
commit
b81f7c48e0
@ -26,10 +26,6 @@ $listOrder = $this->escape($this->state->get('list.ordering'));
|
|||||||
$listDirn = $this->escape($this->state->get('list.direction'));
|
$listDirn = $this->escape($this->state->get('list.direction'));
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<?php if (empty($this->items)) : ?>
|
|
||||||
<p> <?php echo JText::_('COM_WEBLINKS_NO_WEBLINKS'); ?></p>
|
|
||||||
<?php else : ?>
|
|
||||||
|
|
||||||
<form action="<?php echo htmlspecialchars(JUri::getInstance()->toString()); ?>" method="post" name="adminForm" id="adminForm">
|
<form action="<?php echo htmlspecialchars(JUri::getInstance()->toString()); ?>" method="post" name="adminForm" id="adminForm">
|
||||||
<?php if ($this->params->get('filter_field') != 'hide' || $this->params->get('show_pagination_limit')) : ?>
|
<?php if ($this->params->get('filter_field') != 'hide' || $this->params->get('show_pagination_limit')) : ?>
|
||||||
<fieldset class="filters btn-toolbar">
|
<fieldset class="filters btn-toolbar">
|
||||||
@ -50,13 +46,17 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<?php if (empty($this->items)) : ?>
|
||||||
|
<p><?php echo JText::_('COM_WEBLINKS_NO_WEBLINKS'); ?></p>
|
||||||
|
<?php else : ?>
|
||||||
<ul class="category list-striped list-condensed">
|
<ul class="category list-striped list-condensed">
|
||||||
<?php foreach ($this->items as $i => $item) : ?>
|
<?php foreach ($this->items as $i => $item) : ?>
|
||||||
<?php if (in_array($item->access, $this->user->getAuthorisedViewLevels())) : ?>
|
<?php if (in_array($item->access, $this->user->getAuthorisedViewLevels())) : ?>
|
||||||
<?php if ($this->items[$i]->state == 0) : ?>
|
<?php if ($this->items[$i]->state == 0) : ?>
|
||||||
<li class="system-unpublished cat-list-row<?php echo $i % 2; ?>">
|
<li class="system-unpublished cat-list-row<?php echo $i % 2; ?>">
|
||||||
<?php else : ?>
|
<?php else : ?>
|
||||||
<li class="cat-list-row<?php echo $i % 2; ?>" >
|
<li class="cat-list-row<?php echo $i % 2; ?>">
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if ($this->params->get('show_link_hits', 1)) : ?>
|
<?php if ($this->params->get('show_link_hits', 1)) : ?>
|
||||||
<span class="list-hits badge badge-info pull-right">
|
<span class="list-hits badge badge-info pull-right">
|
||||||
@ -83,12 +83,8 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php // Compute the correct link ?>
|
<?php // Compute the correct link ?>
|
||||||
<?php $menuclass = 'category' . $this->pageclass_sfx; ?>
|
<?php $menuclass = 'category' . $this->pageclass_sfx; ?>
|
||||||
<?php $link = $item->link; ?>
|
<?php $link = $item->link; ?>
|
||||||
<?php $width = $item->params->get('width'); ?>
|
<?php $width = $item->params->get('width', 600); ?>
|
||||||
<?php $height = $item->params->get('height'); ?>
|
<?php $height = $item->params->get('height', 500); ?>
|
||||||
<?php if ($width == null || $height == null) : ?>
|
|
||||||
<?php $width = 600; ?>
|
|
||||||
<?php $height = 500; ?>
|
|
||||||
<?php endif; ?>
|
|
||||||
<?php if ($this->items[$i]->state == 0) : ?>
|
<?php if ($this->items[$i]->state == 0) : ?>
|
||||||
<span class="label label-warning"><?php echo JText::_('JUNPUBLISHED'); ?></span>
|
<span class="label label-warning"><?php echo JText::_('JUNPUBLISHED'); ?></span>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
@ -105,20 +101,20 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
case 2:
|
case 2:
|
||||||
// Open in a popup window
|
// Open in a popup window
|
||||||
$attribs = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=' . $this->escape($width) . ',height=' . $this->escape($height) . '';
|
$attribs = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=' . $this->escape($width) . ',height=' . $this->escape($height) . '';
|
||||||
echo "<a href=\"$link\" onclick=\"window.open(this.href, 'targetWindow', '" . $attribs . "'); return false;\">" .
|
echo '<a href="'. $link .'" onclick="window.open(this.href, \'targetWindow\', \'' . $attribs . '\'); return false;">' .
|
||||||
$this->escape($item->title) . '</a>';
|
$this->escape($item->title) . '</a>';
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
// Open in a modal window
|
// Open in a modal window
|
||||||
JHtml::_('behavior.modal', 'a.modal');
|
JHtml::_('behavior.modal', 'a.modal');
|
||||||
echo '<a class="modal" href="' . $link . '" rel="{handler: \'iframe\', size: {x:' . $this->escape($width) . ', y:' . $this->escape($height) . '}}">' .
|
echo '<a class="modal" href="' . $link . '" rel="{handler: \'iframe\', size: {x:' . $this->escape($width) . ', y:' . $this->escape($height) . '}}">' .
|
||||||
$this->escape($item->title) . ' </a>';
|
$this->escape($item->title) . '</a>';
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
// Open in parent window
|
// Open in parent window
|
||||||
echo '<a href="' . $link . '" class="' . $menuclass . '" rel="nofollow">' .
|
echo '<a href="' . $link . '" class="' . $menuclass . '" rel="nofollow">' .
|
||||||
$this->escape($item->title) . ' </a>';
|
$this->escape($item->title) . '</a>';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
@ -126,23 +122,31 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php if ($this->params->get('show_tags', 1) && !empty($item->tags->itemTags)) : ?>
|
<?php if ($this->params->get('show_tags', 1) && !empty($item->tags->itemTags)) : ?>
|
||||||
<?php echo JLayoutHelper::render('joomla.content.tags', $item->tags->itemTags); ?>
|
<?php echo JLayoutHelper::render('joomla.content.tags', $item->tags->itemTags); ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if (($this->params->get('show_link_description')) and ($item->description != '')) : ?>
|
<?php if (($this->params->get('show_link_description')) && ($item->description != '')) : ?>
|
||||||
<?php $images = json_decode($item->images); ?>
|
<?php $images = json_decode($item->images); ?>
|
||||||
<?php if (isset($images->image_first) and !empty($images->image_first)) : ?>
|
<?php if (isset($images->image_first) && !empty($images->image_first)) : ?>
|
||||||
<?php $imgfloat = (empty($images->float_first)) ? $this->params->get('float_first') : $images->float_first; ?>
|
<?php $imgfloat = $images->float_first ?: $this->params->get('float_first'); ?>
|
||||||
<div class="pull-<?php echo htmlspecialchars($imgfloat, ENT_COMPAT, 'UTF-8'); ?> item-image"> <img
|
<div class="pull-<?php echo htmlspecialchars($imgfloat, ENT_COMPAT, 'UTF-8'); ?> item-image">
|
||||||
|
<img
|
||||||
<?php if ($images->image_first_caption) : ?>
|
<?php if ($images->image_first_caption) : ?>
|
||||||
<?php echo 'class="caption" title="' . htmlspecialchars($images->image_first_caption) . '"'; ?>
|
<?php echo 'class="caption" title="' . htmlspecialchars($images->image_first_caption) . '"'; ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
src="<?php echo htmlspecialchars($images->image_first); ?>" alt="<?php echo htmlspecialchars($images->image_first_alt); ?>"/> </div>
|
src="<?php echo htmlspecialchars($images->image_first); ?>"
|
||||||
|
alt="<?php echo htmlspecialchars($images->image_first_alt); ?>"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if (isset($images->image_second) and !empty($images->image_second)) : ?>
|
<?php if (isset($images->image_second) && !empty($images->image_second)) : ?>
|
||||||
<?php $imgfloat = (empty($images->float_second)) ? $this->params->get('float_second') : $images->float_second; ?>
|
<?php $imgfloat = $images->float_second ?: $this->params->get('float_second'); ?>
|
||||||
<div class="pull-<?php echo htmlspecialchars($imgfloat, ENT_COMPAT, 'UTF-8'); ?> item-image"> <img
|
<div class="pull-<?php echo htmlspecialchars($imgfloat, ENT_COMPAT, 'UTF-8'); ?> item-image">
|
||||||
|
<img
|
||||||
<?php if ($images->image_second_caption) : ?>
|
<?php if ($images->image_second_caption) : ?>
|
||||||
<?php echo 'class="caption" title="' . htmlspecialchars($images->image_second_caption) . '"'; ?>
|
<?php echo 'class="caption" title="' . htmlspecialchars($images->image_second_caption) . '"'; ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
src="<?php echo htmlspecialchars($images->image_second); ?>" alt="<?php echo htmlspecialchars($images->image_second_alt); ?>"/> </div>
|
src="<?php echo htmlspecialchars($images->image_second); ?>"
|
||||||
|
alt="<?php echo htmlspecialchars($images->image_second_alt); ?>"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php echo $item->description; ?>
|
<?php echo $item->description; ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
@ -150,8 +154,8 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php endif;?>
|
<?php endif;?>
|
||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
</ul>
|
</ul>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
<?php // Code to add a link to submit a weblink. ?>
|
|
||||||
<?php if ($this->params->get('show_pagination')) : ?>
|
<?php if ($this->params->get('show_pagination')) : ?>
|
||||||
<div class="pagination">
|
<div class="pagination">
|
||||||
<?php if ($this->params->def('show_pagination_results', 1)) : ?>
|
<?php if ($this->params->def('show_pagination_results', 1)) : ?>
|
||||||
@ -162,5 +166,4 @@ $listDirn = $this->escape($this->state->get('list.direction'));
|
|||||||
<?php echo $this->pagination->getPagesLinks(); ?>
|
<?php echo $this->pagination->getPagesLinks(); ?>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</form>
|
</form>
|
||||||
<?php endif; ?>
|
|
||||||
|
Loading…
Reference in New Issue
Block a user