Php Yii:获得一个带有选项的下拉按钮

Php Yii:获得一个带有选项的下拉按钮,php,html,yii,Php,Html,Yii,我的标题有这个代码,它有登录和登录按钮。我希望登录时,注册按钮应该消失,用户名显示(因为它已经发生)和下拉按钮的名称选项,其中有一个注销按钮和一个配置文件按钮。请帮忙,谢谢 <div class="header"> <div class="row logo"> <div class="col-md-1 col-md-offset-1"> <br> <a href='<?

我的标题有这个代码,它有登录和登录按钮。我希望登录时,注册按钮应该消失,用户名显示(因为它已经发生)和下拉按钮的名称选项,其中有一个注销按钮和一个配置文件按钮。请帮忙,谢谢

<div class="header">
    <div class="row logo">
        <div class="col-md-1 col-md-offset-1">
           <br>
           <a href='<?php echo Yii::app()->request->baseUrl;?>/index.php'><p>ERS.com</p></a>
        </div>
        <div class="col-md-9">
          <br>
          <a href="<?php echo Yii::app()->request->baseUrl;?>/user/registration"><p class='pull-right'>SignUp</p></a>
                                        <!--to show the username and logout button in the header upon login-->
  <?php  
   if (Yii::app()->user->isGuest) {
       echo  "<a href='" .  Yii::app()->request->baseUrl . 
       "/user/login'><p class='pull-right' style='margin-right: 12px'>LogIn</p></a>";
    }
    if (!Yii::app()->user->isGuest) {
           echo  '<span style="color: white; font-style: italic; font-size:20px; margin-left:550px">'. Yii::app()->user->name .  "</span> <a href='" .  
                Yii::app()->request->baseUrl . 
                 "/site/logout' ><p class='pull-right' style='margin-right: 12px'>Logout</p></a>";
        }
    ?>

     </div>
   </div><!--row ending here-->
   <div class="row navigation">
     <br>
     <div class="col-md-6 col-md-offset-3">
        <ul class="nav nav-pills">
          <li role="presentation"><a href="<?php echo yii::app()->request->baseUrl;?>/index.php"><p>Home</p></a></li>
          <li role="presentation"><a href="<?php echo yii::app()->request->baseUrl;?>/ngo/allngo"><p>Ngo's</p></a></li>
          <li role="presentation"><a href="<?php echo yii::app()->request->baseUrl;?>/blog/allblog"><p>Blogs</p></a></li>
          <li role="presentation"><a href="<?php echo yii::app()->request->baseUrl;?>/story/allstory"><p>Stories</p></a></li>
          <li role="presentation"><a href="<?php echo yii::app()->request->baseUrl;?>/event/allevent"><p>Events</p></a></li>
          <li role="presentation"><a href="<?php echo yii::app()->request->baseUrl;?>/"><p>Report</p></a></li>
       </ul>
        <br>
     </div>
   </div><!--row ending here-->                                  
 </div> <!--header ending here-->
<!-- <div class="row">
      <?php $this->widget('zii.widgets.CMenu',array(
        'items'=>array(
            array('label'=>'Home', 'url'=>array('/site/index')),
            array('label'=>'About', 'url'=>array('/site/page', 'view'=>'about')),
            array('label'=>'Contact', 'url'=>array('/site/contact')),
            array('label'=>'Login', 'url'=>array('/site/login'), 'visible'=>Yii::app()->user->isGuest),
            array('label'=>'Logout ('.Yii::app()->user->name.')', 'url'=>array('/site/logout'), 'visible'=>!Yii::app()->user->isGuest)
        ),
    )); ?>
</div>-->