<?php Yii::app()->clientScript->scriptMap = array('jquery.js'=>false);?>
<div class="form">
<fieldset>
    <legend>修改 <?php echo $member->username;?> 的昵称</legend>
    <?php
    $form = $this->beginWidget('CActiveForm', array(
            'id' => 'uname',
            'action' => $this->createUrl('member/username',array('uid'=>$member->uid)),
            'enableAjaxValidation' => true,
            'enableClientValidation' => true,
            'htmlOptions' => array(
                'class' => 'form',
            ),
        )
    );
    ?>
    新昵称：<?php echo $form->textField($member, 'username', array('value'=>''));?><?php echo $form->error($member, 'username');?>
    <br/>
    <?php echo CHtml::ajaxSubmitButton('保存', '', array('success'=>'js:function(status){ if (1 == status) {$.fancybox.close(); $("#oname").html($("#Member_username").val());} }')); ?>
    <?php $this->endWidget();?>
</fieldset>
</div>