Board index   FAQ   Search  
Register  Login
Board index php forum :: HTML JavaScript

length is null or not an object error in IE8

Javascript coding ..

Moderators: macek, egami, gesf

length is null or not an object error in IE8

Postby jebaraj747 » Mon Sep 26, 2011 10:27 pm

Hi,
I have added an validation script for Pizza menu. Validation working fine in all browsers except IE.
When I working in IE8 it throws an error "length is null or not an object error in IE8".
Please help me. See Java script code below:
<script>
function UnCheckRadios(radioButtonGroupName)
{

var formName = "frmOrder";
var form = document.forms[formName];
alert(form);
var noOfRadioButtons=form[radioButtonGroupName].length;
for(var x=0;x<noOfRadioButtons;x++)
{
chk=form[radioButtonGroupName]
.checked=false;

}
}
</script>

PHP code:
<input type="radio" id="<?=$subitem['subgroup_id'];?>_comboleft" name="<?=$subitem['subgroup_id'];?>_comboleft" value="<?=$subitem['id'];?>:Left Side" onclick="UnCheckRadios('<?=$subitem["subgroup_id"];?>_combowhole');">
jebaraj747
New php-forum User
New php-forum User
 
Posts: 2
Joined: Mon Sep 26, 2011 10:25 pm

Return to JavaScript

Who is online

Users browsing this forum: Google [Bot] and 1 guest

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.

cron