helpers/Nav.php
public static function side($items, $htmlOptions = array())
    {
        ArrayHelper::addValue('class', Enum::NAV_SIDE, $htmlOptions);
        ob_start();
        echo \CHtml::openTag('ul', $htmlOptions);
        foreach ($items as $item) {

            if (is_string($item)) // treat as divider
            echo \CHtml::tag('li', array('class' => Enum::NAV_DIVIDER));
            else {
                $itemOptions = ArrayHelper::getValue($item, 'itemOptions', array());
                $linkOptions = ArrayHelper::getValue($item, 'linkOptions', array());
                $label       = ArrayHelper::getValue($item, 'label', 'Item');
                $url         = ArrayHelper::getValue($item, 'url', '#');

                echo \CHtml::openTag('li', $itemOptions);
                echo \CHtml::link($label, $url, $linkOptions);
                echo \CHtml::closeTag('li');
            }
        }
        echo \CHtml::closeTag('ul');

        return ob_get_clean();
    }
public static function side($items, $htmlOptions = array())
    {
        ArrayHelper::addValue('class', Enum::NAV_SIDE, $htmlOptions);
        ob_start();
        echo \CHtml::openTag('ul', $htmlOptions);
        foreach ($items as $item) {

            if (is_string($item)) // treat as divider
            echo \CHtml::tag('li', array('class' => Enum::NAV_DIVIDER));
            else {
                $itemOptions = ArrayHelper::getValue($item, 'itemOptions', array());
                $linkOptions = ArrayHelper::getValue($item, 'linkOptions', array());
                $label       = ArrayHelper::getValue($item, 'label', 'Item');
                $url         = ArrayHelper::getValue($item, 'url', '#');

                echo \CHtml::openTag('li', $itemOptions);
                echo \CHtml::link($label, $url, $linkOptions);
                echo \CHtml::closeTag('li');
            }
        }
        echo \CHtml::closeTag('ul');

        return ob_get_clean();
    }
public static function side ( $ items , $ htmlOptions = array ( ) ) { ArrayHelper :: addValue ( 'class' , Enum :: NAV_SIDE , $ htmlOptions ) ; ob_start ( ) ; echo \ CHtml :: openTag ( 'ul' , $ htmlOptions ) ; foreach ( $ items as $ item ) { if ( is_string ( $ item ) ) // treat as divider echo \ CHtml :: tag ( 'li' , array ( 'class' => Enum :: NAV_DIVIDER ) ) ; else { $ itemOptions = ArrayHelper :: getValue ( $ item , 'itemOptions' , array ( ) ) ; $ linkOptions = ArrayHelper :: getValue ( $ item , 'linkOptions' , array ( ) ) ; $ label = ArrayHelper :: getValue ( $ item , 'label' , 'Item' ) ; $ url = ArrayHelper :: getValue ( $ item , 'url' , '#' ) ; echo \ CHtml :: openTag ( 'li' , $ itemOptions ) ; echo \ CHtml :: link ( $ label , $ url , $ linkOptions ) ; echo \ CHtml :: closeTag ( 'li' ) ; } } echo \ CHtml :: closeTag ( 'ul' ) ; return ob_get_clean ( ) ; }
Generates a side nav

@param array $items the link items to display as a side nav. The items have the following format:
<pre>
array('label'=>'Item', 'url'=>'#', 'linkOptions'=>array(), 'itemOptions'=>array())
</pre>
@param array $htmlOptions
@return string
@see http://foundation.zurb.com/docs/components/side-nav.html
Generates a side nav