How to check if a div is visible in jQuery
To check whether a div is visible or not in the layout , we can simply use the JQuery :visible selector.
Example : check if a div is visible state or not. #
<script>
$(document..ready(function(){
$("button").click(function(){
if($("p").is(":visible")){
alert("The paragraph is visible.");
} else{
alert("The paragraph is hidden.");
}
});
});
</script>
Try it Yourself »
save
listen
AI Answer
How to check if a div is visible in jQuery
0
To check whether a div is visible or not in the layout , we can simply use the JQuery :vi…
asked
Apu
0 answers
2915
To check whether a div is visible or not in the layout , we can simply use the JQuery :vi…
Answer Link
answered
Apu