Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

thezip's scratchpad

by thezip (Vicar)
on Feb 15, 2007 at 16:36 UTC ( #600240=scratchpad: print w/ replies, xml ) Need Help??

A jQuery question:

Given the following html, how can I get the contents of the div, jims_class, to show and hide depending upon the checked status of the mybox1 checkbox?

<script> if ($('#mybox1').attr('checked')) { $('.jims_class').show()); } else { $('.jims_class').hide()); } </script> <form> <input type="checkbox" name="mybox1" id="mybox1"> <input type="checkbox" name="mybox2" id="mybox2"> </form> <div class="jims_class"> Conditionally show this text depending on the checked status of mybox1 +... </div>
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2013-05-26 09:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best material for plates (tableware) is:









    Results (525 votes), past polls