Checkbox Text
General
The user no longer needs to click precisely on the checkbox to check and uncheck it. Clicking the text after the checkbox will also select it.
Notes
- Posted: July 20, 2000
Source Code
Paste this source code into the designated areas.
External file
Paste this code into an external JavaScript file named: checkboxText.js
Head
Paste this code into the HEAD section of your HTML document.
Body
Paste this code into the BODY section of your HTML document


Leave a Response
(3 comments)Yes, but there are times when that is not possible. For instance, when a table is being used for layout, and the label is in one cell and its associated control is in another cell.
Just use the (X)HTML <label> tag to put focus onto a specific input object. For example:[br /]<input type="checkbox" name="checkboxName" id="checkme"> <label for="checkme">Select this checkbox</label>[br /][br /][br /]Problem solved! Now, all of your visitors (with or without JavaScript enabled) can click on the text.
nice script it solved my problem.