[jQuery] Re: is(':checked') always returns false

2009-10-02 Thread Matt Kruse
On Oct 1, 1:16 pm, bob.nel...@gmail.com bob.nel...@gmail.com wrote: I have a bunch of checkboxes that I want to have checked when the user checks a master checkbox. You are writing too much unnecessary jQuery code! HTML for master checkbox (within a container with id 'msgsInbox'): input

[jQuery] Re: is(':checked') always returns false

2009-10-01 Thread MorningZ
You've got issues elsewhere in your code that you don't show: http://jsbin.com/ocode/edit On Oct 1, 2:16 pm, bob.nel...@gmail.com bob.nel...@gmail.com wrote: I have a bunch of checkboxes that I want to have checked when the user checks a master checkbox. I've done this before and reused the

[jQuery] Re: is(':checked') always returns false

2009-10-01 Thread Bob
Interesting discovery. Going back to the code that works, if I alert is (':checked') in the working code, it also returns false ALWAYS, but it still works. Still looking for a solution.

[jQuery] Re: is(':checked') always returns false

2009-10-01 Thread Bob
Thanks for the link MorningZ I obviously have issues elsewhere in my code, but I can't paste my entire site here. I'm looking for suggestions on what MIGHT be causing this since there is no obvious error at the moment. On Oct 1, 11:39 am, Bob bob.nel...@gmail.com wrote: Interesting discovery.

[jQuery] Re: is(':checked') always returns false

2009-10-01 Thread James
Do you have another element on your site with id=msgCheckAllInbox? IDs are suppose to be unique in the entire HTML document. On Oct 1, 8:53 am, Bob bob.nel...@gmail.com wrote: Thanks for the link MorningZ I obviously have issues elsewhere in my code, but I can't paste my entire site here.

[jQuery] Re: is(':checked') always returns false

2009-10-01 Thread Bob
I've already done a site wide search. I only have one element with that unique ID. That was my first thought too. On Oct 1, 12:02 pm, James james.gp@gmail.com wrote: Do you have another element on your site with id=msgCheckAllInbox? IDs are suppose to be unique in the entire HTML document.

[jQuery] Re: is(':checked') always returns false

2009-10-01 Thread James
Oops, sorry. I missed your text at the bottom of your initial post. Try doing it like how MorningZ did in his code. Separate the code: onclick=checkAllMsgsIn() and try onchange. I think what maybe happening is that the function is executing before the actual checkbox is checked, thus