This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes Checkbox validation - at least one selected Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Checkbox validation - at least one selected" Watch "Checkbox validation - at least one selected" New topic
Author

Checkbox validation - at least one selected

M sallu
Ranch Hand

Joined: Dec 13, 2009
Posts: 42
Hi, I have number of checkboxes and another checkbox for "Select All"

I want to check if the user has selected at least one checkbox. Need modification in javascript

Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 32507
    
214

Before getting to the JavaScript, you need to design the HTML. What are your checkboxes called? How do you identify each one? A number, a different name, an array? Show some more of the HTML.


[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 63227
    
  69

And be sure to use proper formatting and indentation in your code. Unformatted code s surprisingly hard to read.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
M sallu
Ranch Hand

Joined: Dec 13, 2009
Posts: 42
Done

 
Have you checked out Aspose?
 
subject: Checkbox validation - at least one selected
 
It's not a secret anymore!