Revision #47 has been created by Rohit Suthar on Nov 26, 2014, 9:16:27 AM with the memo:
add hidden field source code
« previous (#46) next (#48) »
Changes
Title
unchanged
By Example: CHtml
Category
unchanged
Tutorials
Yii version
unchanged
Tags
unchanged
listData, chtml, link, button, ByExample, ajax, ajax link, image
Content
changed
[...]
```php
<?php echo CHtml::textField('Text', 'some value',
array('disabled'=>'disabled'); ?>
```
***
**Example 5: Generating a hidden textfield**
```php
<?php echo CHtml::hiddenField('Text', 'some value',
array('id'=>'idTextField'); ?>
```
## CHtml::listData() method
~~~
public static function listData($models,$valueField,$textField,$groupField='')
~~~
Generates data for dropDownList and listBox, using the format $key=>$value.[...]