Home
|
Tutorials
|
Articles
|
Videos
|
Products
|
Tools
|
Search
Interviews
|
Open Source
|
Tag Cloud
|
Follow Us
|
Bookmark
|
Contact
In Browser
StumbleUpon
del.icio.us
Google
Google Buzz
reddit
LinkedIn
Facebook
Twitter
Linkedin
E-Mail
Home
Tutorials
Articles
Search Tutorials
Products
Authors
Submit a Tutorial
Report a Bug
Interview FAQ
Subscribe
Articles
>
jQuery
> How to check whether a checkbox is checked in jQuery
How to check whether a checkbox is checked in jQuery
Author:
Venkata Sudhakar
The below example shows how to check whether a checkbox is checked in
jQuery
.
//jQuery version >= 1.0 if($("#licenseAgreement").is(':checked')) { //License checkbox checked } else { //License checkbox not checked } //jQuery version >= 1.6 if($("#licenseAgreement").prop('checked')) { //License checkbox checked } else { //License checkbox not checked } //Using plain Javascript if(document.getElementById('licenseAgreement').checked) { //License checkbox checked } else { //License checkbox not checked }
Home
|
Tutorials
|
Random Tutorial
|
Articles
|
Videos
|
Search
|
Google Search
|
Products
|
Student Projects
|
Open Source
Tools
|
Tips And Tricks
|
How to Fix
|
Tag Cloud
|
Share
|
Disclaimer
|
Privacy
|
Contact
|
Login
Send your comments, suggestions or queries regarding this site to
[email protected]
.
Copyright © 2008-2024. All rights reserved.