<?php
$this->pageTitle = 'Сохранение персонажа';
?>
<?php
$form = $this->beginWidget('CActiveForm', array(
    'id' => 'save-form',
    'htmlOptions'=>array(
      'role'=>'form',
    ),
));
?>
<div class="form-group">
    <?php echo $form->labelEx($save, 'login', array('class' => 'control-label')); ?>
    <?php echo $form->textField($save, 'login', array('class' => 'form-control', 'placeholder' => $save->getAttributeLabel('login'))); ?>
    <?php echo $form->error($save, 'login'); ?>
</div>
<?php if (!isset($_SERVER['HTTP_X_HOST'])):?>
    <div class="form-group">
        <?php echo $form->labelEx($save, 'password', array('class' => 'control-label')); ?>
        <?php echo $form->passwordField($save, 'password', array('class' => 'form-control', 'placeholder' => $save->getAttributeLabel('password'))); ?>
        <?php echo $form->error($save, 'password'); ?>
    </div>
    <div class="form-group">
        <?php echo $form->labelEx($save, 'password_confirm', array('class' => 'control-label')); ?>
        <?php echo $form->passwordField($save, 'password_confirm', array('class' => 'form-control', 'placeholder' => 'Повторите пароль')); ?>
        <?php echo $form->error($save, 'password_confirm'); ?>
    </div>
<?php endif; ?>
<div class="form-group">
    <?php echo $form->labelEx($save, 'sex', array('class' => 'control-label')); ?>
    <?php echo $form->dropDownList($save, 'sex', array('0'=>'мужской','1'=>'женский'), array('class' => 'form-control')); ?>
    <?php echo $form->error($save, 'sex'); ?>
</div>
<?php if (!isset($_SERVER['HTTP_X_HOST'])):?>
    <div class="form-group">
        <?php echo $form->labelEx($save, 'email', array('class' => 'control-label')); ?>
        <?php echo $form->textField($save, 'email', array('class' => 'form-control', 'placeholder' => $save->getAttributeLabel('email'))); ?>
        <?php echo $form->error($save, 'email'); ?>
    </div>
<?php endif; ?>
<?php echo CHtml::submitButton(Yii::t('layout', 'Сохранить'), array('class' => 'btn-block form-control')); ?>
<?php $this->endWidget(); ?>
