I am trying a sample application in yii.. I faced a problem when I created new view page name with cart.php. In this page I am trying to access model variable.Where it is saying undefined variable model..
View page
<div class="form">
<?php $form=$this->beginWidget('CActiveForm', array(
'id'=>'login-form',
'enableClientValidation'=>true,
'clientOptions'=>array(
'validateOnSubmit'=>true,
),
)); ?>
<div>
<?php echo $form->labelEx($model,'cartId:'); ?>
<?php echo $form->textField($model,'cartId',array('size'=>20,'maxlength'=>120)); ?>
<?php echo $form->error($model,'cartId'); ?>
</div>
<?php $this->endWidget(); ?>
</div>