This week's book giveaway is in the Android forum.
We're giving away four copies of Head First Android and have Dawn & David Griffiths on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes How to find Checkboxes? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "How to find Checkboxes?" Watch "How to find Checkboxes?" New topic

How to find Checkboxes?

Krishna Srinivasan
Ranch Hand

Joined: Jul 28, 2003
Posts: 1849

I want to iterate the checkboxes in form?
Is there any way to find the checkboxes in a form. like getting number of checkboxes in the form.

Krishna Srinivasan
OCAJP 7/8 Exam, 400+ OCPJP Mock Questions
Valentin Crettaz
Gold Digger

Joined: Aug 26, 2001
Posts: 7610
You can find many examples on the web, but here goes.

Using normal JavaScript (NB: I have not run this code):

Using jQuery:

More info at

[Blog] [Blogroll] [My Reviews] My Linked In
I agree. Here's the link:
subject: How to find Checkboxes?
jQuery in Action, 3rd edition