Sencha Touch/extjs form in HTML
The checkbox in HTML is selected, value is Yes, no is selected
<input type= "text" name= "Text1" >
<input type= "text" name= "Text2" >
<input type= "text" name= "Text3" >
<input name= "CheckBox1" type= "checkbox" value= "No" class= "Duigou" >
<input name= "CheckBox2" type= "checkbox" value= "No" class= "Duigou" >
<input name= "Checkbox3" type= "checkbox" value= "No" class= "Duigou" >
1. Get all the input boxes first
var viewport=ext.viewport.down (' #视图ID ')
var inputfields=viewport.innerelement.dom.queryselectall (' input ');//Find all the input boxes in the view
2. Find the checkbox, judge if it is checked, then change the value to Yes
for (var i = 0; i < inputfields.length; i++)
{
if (inputfields[i][' type ']== ' checkbox ' && inputfields[i].checked)/is a checkbox and is selected, the value is changed to
Yes
{
Inputfields[i].value= ' yes ';
}
.....
}
http://blog.csdn.net/l863784757/article/details/15502069