How To Change The Width Of The Textfields In Yii Form

hello guys…

Can anyone give me the idea about how to do that???I need to set the textfield accoding to given sizes.thusfar it look same sizes.help me

try


  <?php echo $form->textField($model, 'ticket_type',array('class'=>'width274')); ?>


<style>

.width274{width: 274px;}

</style>

mmmmm this is not the sollution that I expected.when i create the db table with relevent sizes for the text field then I need to width of text field match with database table sizes;

ex

username var( 45)

password var(20)

;I need the diferent sizes for above text fields in the form in yii

you can check the model validation rules


array('username', 'length', 'max'=>45),

try ../views/../_form.php




<?php echo $form->textField($model,'username',array('size'=>45,'maxlength'=>45)); ?>

<?php echo $form->textField($model,'password',array('size'=>20,'maxlength'=>20)); ?>



hey thanx lot dr.It works