Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

onclick checkbox hide div and unchecked show div

$(".answer").hide();
$(".coupon_question").click(function() {
    if($(this).is(":checked")) {
        $(".answer").show(300);
    } else {
        $(".answer").hide(200);
    }
});
Comment

PREVIOUS NEXT
Code Example
Javascript :: js alert 
Javascript :: how to print the value of variable in javascript in html 
Javascript :: how to convert new date to dd/mm/yyyy format in javascript 
Javascript :: javascript remove duplicate in two arrays 
Javascript :: javascript object first key 
Javascript :: settimeout 
Javascript :: avascript sleep 1 second 
Javascript :: unpack list javascript 
Javascript :: get nearby store by latitude and longitude from my latitude and long node js 
Javascript :: jquery open image in new tab 
Javascript :: javascript check if element is overflowing 
Javascript :: js find all text elements 
Javascript :: check fro text input jquery 
Javascript :: postman test save token 
Javascript :: js replace characters in a string 
Javascript :: remove text javascript 
Javascript :: vue get props into data 
Javascript :: val select jquery 
Javascript :: jquery modify style attribute 
Javascript :: postgresql update json field key value 
Javascript :: vuejs string contains 
Javascript :: javascript console output 
Javascript :: navigate-to-an-anchor-on-another-page 
Javascript :: javascript backticks 
Javascript :: math.rount 
Javascript :: remove element from an array 
Javascript :: import bootstrap css and js file in react 
Javascript :: how to cut a string in js 
Javascript :: filter includes array 
Javascript :: select add option javascript 
ADD CONTENT
Topic
Content
Source link
Name
8+8 =