I'm pretty new to the jQuery world, so I'm hoping for some help.
I am creating a page that has a div that has a number of checkboxes inside of it.
Each of these checkboxes are contained in their own divs as well.
<div>
<div>
<input type='checkbox' name='cb1' />
<div id="info1">
Hide
</div>
</div>
<div>
<input type='checkbox' name='cb2' />
<div id="info2">
Hide
</div>
</div>
</div>
I need to write a jQuery function that be able to capture whenever either checkbox (cb1 or cb2) is clicked to hide/show it's corresponding 'info' div, (info1 or info2).
I'm going to have 100+ checkboxes so I'm hoping there is a way to do this without having to write 100+ functions for click().
Thanks,
Mark