PHP
OOPs
JavaScript
JQuery
Ajax
Codeigniter
Laravel
MySql
Node.js
Tutorials
C
C++
Json
Codeigniter 4
htaccess
wordpress
react.js
Blogs
Fundamental
Python
Search Your Query
×
--- Select Category ---
PHP
OOPs
JavaScript
JQuery
Ajax
Codeigniter
Laravel
MySql
Node.js
Tutorials
Blogs
Fundamental
Python
Most Popular Tutorials
What is Javascript
BOM (Browser object model)
DOM (Document object model)
Variable
Variable is empty or Not
Javascript output
Function
Events
Array
Get text value
Get Form field value
Pattern validation
Form validation
Checkbox validation
Inner Html form validation
Form validation on php server
Window and window location
Get Text Value
get javascript value in php
Date Format
Get php variable in javascript
Redirect page in javascript
Auto Refresh page and DIV
Get text value from dropdown
Clear Browser History
Get Checkbox value
select (Dropdown)
PopUp Contact Form
sidebar contact form
Show modal on page load
Auto calculate price GST
print html and Div content
Calculate Discount prince
Checked single or all checkbox
Auto Fill form data on click checkbox
Show subcategory (Dependent Dropdown)
country, state, city (Dependent Dropdown)
Image upload with preview image
Filter table data
Character Limit Validation
uploading file size validation
Special Character validation
multiple file upload (Add more)
function call after page load
Disable Submit Button After Form Submission
disable browser back button
Remove selected item from second & third dropdown list
Interview Question
Active Tab Menu
String methods
Tutorials Menus
What is Javascript
BOM (Browser object model)
DOM (Document object model)
Variable
Variable is empty or Not
Javascript output
Function
Events
Array
Get text value
Get Form field value
Pattern validation
Form validation
Checkbox validation
Inner Html form validation
Form validation on php server
Window and window location
Get Text Value
get javascript value in php
Date Format
Get php variable in javascript
Redirect page in javascript
Auto Refresh page and DIV
Get text value from dropdown
Clear Browser History
Get Checkbox value
select (Dropdown)
PopUp Contact Form
sidebar contact form
Show modal on page load
Auto calculate price GST
print html and Div content
Calculate Discount prince
Checked single or all checkbox
Auto Fill form data on click checkbox
Show subcategory (Dependent Dropdown)
country, state, city (Dependent Dropdown)
Image upload with preview image
Filter table data
Character Limit Validation
uploading file size validation
Special Character validation
multiple file upload (Add more)
function call after page load
Disable Submit Button After Form Submission
disable browser back button
Remove selected item from second & third dropdown list
Interview Question
Active Tab Menu
String methods
Share On Facebook
How to Checked single or all checkbox in javascript?
onClick Checkbox check all checkbox Using Javascript
File name : index.php
<!DOCTYPE html>
<html>
<body>
<head>
<title>Onclick Checkbox check all checkbox in Javascript</title>
</head>
<input type="checkbox" onClick="toggle(this)" /> Select All<br/>
<input type="checkbox" name="check" value="check1"> check 1<br/>
<input type="checkbox" name="check" value="check2"> check 2<br/>
<input type="checkbox" name="check" value="check3"> check 3<br/>
<input type="checkbox" name="check" value="check4"> check 4<br/>
<script>
function toggle(source) {
checkboxes = document.getElementsByName('check');
for(var i=0, n=checkboxes.length;i<n;i++) {
checkboxes[i].checked = source.checked;
}
}
</script>
</body>
</html>
Output :-
Onclick Checkbox check all checkbox in Javascript
Select All
check 1
check 2
check 3
check 4
Share On Facebook
Previous
Next
Trending Tutorials
PHP
100+ Tutorials
PHP OOPs
80+ Tutorial
Codeigniter
100+ Tutorial
Laravel
100+ Tutorials
NODE.JS
100+ Tutorials
Javascript
100+ Tutorials
Download Live Projects
Review & Rating
0.0
/ 5
0
Review
5
(
0
)
4
(
0
)
3
(
0
)
2
(
0
)
1
(
0
)
Write Review Here
Review
Submit Review
×
Submit
Ittutorial
Ittutorial
Most Popular Tutorials
Image upload with preview image
Show subcategory (Dependent Dropdown)
Special Character validation
Form validation on php server
Get Text Value
disable browser back button
multiple file upload (Add more)
Get Checkbox value
select (Dropdown)
Date Format
Auto Fill form data on click checkbox
Get text value
Get php variable in javascript
DOM (Document object model)
Function
Auto Refresh page and DIV
sidebar contact form
Interview Question
PopUp Contact Form
uploading file size validation
Important Link
Core php Online Advance Tutorails and video Tutorials.
How to manage Session in php Tutorials.
More .......
upcomming codeigniter and angular js tutorials.
Click here to see More ...
Hello Friend Please Follow & Share Ittutorial.
×
Ittutorial
Please Follow and Share ittutorial.
Ittutorial