It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming JavaScript Forum

bug firefox checkboxes

bug firefox checkboxes

Postby cmitsis on Fri Aug 01, 2008 1:56 pm

i have a problem with firefox...
i have a form with some checkboxes and a checkbox "all" that when i click on it all the checkboxes(box1,box2) must be clicked at the same time.

i created this function:

function clickbox(checkbox)
{
if(checkbox.checked==true)
{
document.getElementById('box1').checked=true;
document.getElementById('box2').checked=true;
}
else
{
document.getElementById('box1').checked=false;
document.getElementById('box2').checked=false;
}
}

and then i have:

<input name="all" type="checkbox" onclick="javascript:clickbox(this);">

this works fine at IE but not in firefox.

any solution???
cmitsis
 
Posts: 0
Joined: Fri Aug 01, 2008 1:47 pm

Postby dflynn on Fri Aug 01, 2008 8:31 pm

Post in HTML or Javascript. This is Bug as in DEVPPL Forum bugs. Not your bugs.
User avatar
dflynn
500+ Club
 
Posts: 860
Joined: Wed Oct 03, 2007 9:06 pm
Location: Guelph, Canada

Postby rangana on Sat Aug 02, 2008 3:02 am

I believe webmaster will move this thread later. Meanwhile, show us your complete code, I can't see in your markups that you have box1 and box2 id being declared.

Also note that IE being buggy regards name and id synonymous, so most probably the problem is in you and not on FF. Ensure you have box1 and box2 id. With that said, the code should work.

If nothing works, up the rest of the markup so we could have a closer look.
User avatar
rangana
500+ Club
 
Posts: 935
Joined: Wed Feb 27, 2008 5:14 am
Location: Cebu City Philippines


Who is online

Users browsing this forum: No registered users and 5 guests