Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7635319
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T07:24:08+00:00 2026-05-31T07:24:08+00:00

I have looked for hours on the web with no luck! I have 40

  • 0

I have looked for hours on the web with no luck!

I have 40 Check boxes, one check box must be checked at all times. Here’s the twist, that one check box must be any one of the 40.

I know how to target just one single button…this is not the goal. The user must be able to choose which one is to remain active.

      $(document).ready(function() {
      $('#W_E-helpPage01').click(function() {
         return false;

As for form validation that’s not the ticket either. As this needs to be dynamic, it must prevent the user from deselecting all but one check box.

Example:
If 30 where to be check, and the user decided to uncheck all 30 he can not do this. As the rule is there must always be at-less one check, it doesn’t matter which one but it must be random.

Any help would be greatly appreciated.

Thanks,
Ricky

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T07:24:09+00:00Added an answer on May 31, 2026 at 7:24 am

    This code will stop the user from unchecking the last checked checkbox:

    $('input:checkbox').on('click', function() {    
        if ($('input:checkbox:checked').length == 0) {
            return false;
        }
    });​
    

    It checks to see if this click results in there being no checked check boxes and cancels the click if that is true.

    http://jsfiddle.net/BQCK3/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have looked on the web to find a list of all Python keywords
So I have looked about on here and web in general and cant find
Have looked quite hard for this answer but having no luck. I have 3
I have looked all over and cannot figure out why this code isn't working.
I have looked but have not found a specific answer for changing just one
I have looked here and from what I understand the following regex simply means
I have looked at the other questions on here about this. It isn't working.
I have been searching for about 2 hours now without any luck, maybe I
I have looked for several hours for a good tutorial on how to store
I have looked at this for hours and can't seem to figure out what

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.