yii CMenu的配置(导航栏)
给主键的li 和a标签添加元素
$this->myMenu = array( 'id'=>'myMenu', 'items'=>array( array( 'label'=>'Home', 'url'=>array('site/index'), 'itemOptions'=>array('class'=>'visited'), 'linkOptions'=>array('class'=>'bar'), ), array('label'=>'Sign Out', 'url'=>array('site/signout')), ), );
给ul添加元素
$this->widget('zii.widgets.CMenu', array( 'id'=>'myMenu', 'items'=>$this->myMenu, 'htmlOptions'=>array('class'=>'span-24 last'), ));
this will make Yii render
<ul class="span-24 last" id="myMenu">
...
</ul>