public function getLimitBox()
{
$app = Factory::getApplication();
// Initialize variables
$limits = array();
// Make the option list
for ($i = 5; $i <= 30; $i += 5) {
$limits[] = HTMLHelper::_('select.option', "{$i}");
}
$limits[] = HTMLHelper::_('select.option', '50');
$limits[] = HTMLHelper::_('select.option', '100');
$limits[] = HTMLHelper::_('select.option', '0', Text::_('COM_PHOCAGALLERY_ALL'));
$selected = $this->viewall ? 0 : $this->limit;
// Build the select list
if ($app->isClient('administrator')) {
$html = HTMLHelper::_('select.genericlist', $limits, 'limitsubcat', 'class="form-control input-mini" size="1" onchange="Joomla.submitform();"', 'value', 'text', $selected);
} else {
$html = HTMLHelper::_('select.genericlist', $limits, 'limitsubcat', 'class="form-control input-mini" size="1" onchange="this.form.submit()"', 'value', 'text', $selected);
}
return $html;
}