hushanjun
04-24-2007, 01:22 PM
while i create a form like next code:
var form = new Ext.form.Form({id:'cron',
action:'action',
labelAlign: 'right',
labelWidth: 75});
form.column({width:570,labelWidth:100, labelAlign: 'left',clear:true});
form.fieldset({legend:' ',width:550});
form.column(
{width:290, labelWidth:93},
new Ext.form.TextField({
fieldLabel: 'name',
name: 'name',
width:170,
allowBlank:false
})
);
form.addButton({text:'ok'},function(){form.submit( );});
when i click the button 'ok',firebug report a error,i found it raise by the code from the method 'setForm' of the class YAHOO.util.Connect,i traced,and found that the code in line 748:
// Iterate over the form elements collection to construct the
// label-value pairs.
for (var i=0; i<oForm.elements.length; i++)
because the firefox don't support the 'elements' properties , how can resolve it?
var form = new Ext.form.Form({id:'cron',
action:'action',
labelAlign: 'right',
labelWidth: 75});
form.column({width:570,labelWidth:100, labelAlign: 'left',clear:true});
form.fieldset({legend:' ',width:550});
form.column(
{width:290, labelWidth:93},
new Ext.form.TextField({
fieldLabel: 'name',
name: 'name',
width:170,
allowBlank:false
})
);
form.addButton({text:'ok'},function(){form.submit( );});
when i click the button 'ok',firebug report a error,i found it raise by the code from the method 'setForm' of the class YAHOO.util.Connect,i traced,and found that the code in line 748:
// Iterate over the form elements collection to construct the
// label-value pairs.
for (var i=0; i<oForm.elements.length; i++)
because the firefox don't support the 'elements' properties , how can resolve it?