Skip to content

Commit

Permalink
Merge branch 'staging' of github.com:manojLondhe/joomla-cms into list…
Browse files Browse the repository at this point in the history
…views
  • Loading branch information
Manoj L committed Oct 29, 2014
2 parents fce4d97 + 612efe3 commit eda0cb9
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 6 deletions.
10 changes: 7 additions & 3 deletions administrator/components/com_content/helpers/content.php
Expand Up @@ -32,16 +32,20 @@ public static function addSubmenu($vName)
JHtmlSidebar::addEntry(
JText::_('JGLOBAL_ARTICLES'),
'index.php?option=com_content&view=articles',
$vName == 'articles'
$vName == 'articles',
'stack'
);
JHtmlSidebar::addEntry(
JText::_('COM_CONTENT_SUBMENU_CATEGORIES'),
'index.php?option=com_categories&extension=com_content',
$vName == 'categories');
$vName == 'categories',
'folder'
);
JHtmlSidebar::addEntry(
JText::_('COM_CONTENT_SUBMENU_FEATURED'),
'index.php?option=com_content&view=featured',
$vName == 'featured'
$vName == 'featured',
'star'
);
}

Expand Down
7 changes: 6 additions & 1 deletion layouts/joomla/sidebars/submenu.php
Expand Up @@ -36,7 +36,12 @@
<a class="nolink"><?php echo $item[0]; ?></a>
<?php else :
if (strlen($item[1])) : ?>
<a href="<?php echo JFilterOutput::ampReplace($item[1]); ?>"><?php echo $item[0]; ?></a>
<a href="<?php echo JFilterOutput::ampReplace($item[1]); ?>">
<?php if (isset ($item[3]) && !empty($item[3])) : ?>
<span class="icon-<?php echo $item[3];?>"></span>
<?php endif; ?>
<?php echo $item[0]; ?>
</a>
<?php else : ?>
<?php echo $item[0]; ?>
<?php endif;
Expand Down
5 changes: 3 additions & 2 deletions libraries/cms/html/sidebar.php
Expand Up @@ -73,14 +73,15 @@ public static function render()
* @param string $name Name of the menu item.
* @param string $link URL of the menu item.
* @param bool $active True if the item is active, false otherwise.
* @param string $icon Name of the icon class.
*
* @return void
*
* @since 3.0
*/
public static function addEntry($name, $link = '', $active = false)
public static function addEntry($name, $link = '', $active = false, $icon = '')
{
array_push(static::$entries, array($name, $link, $active));
array_push(static::$entries, array($name, $link, $active, $icon));
}

/**
Expand Down

0 comments on commit eda0cb9

Please sign in to comment.