Javatpoint Logo

about jquery div size changer

By: priya2*** On: Tue Jan 17 05:10:20 IST 2017     Question Reputation0 Answer Reputation0 Quiz Belt Series Points0  0Blank User
i put hover method when select a div to change color another div.and i put a condition for height with hover. i want after run my codes , when i change div height and save to change div color another div.
my code is
<!DOCTYPE html>
<html>
<head>
<title>toggle Class with Advertise</title>
<script src="jquery-3.1.1.min.js"></script>
<style>
#test {
background : yellow;
height : 400px;
}
#contain {
background : orange;
}
#para {
color : orange;
}
.active {
background : green;
}
.try (
background : orange;
)
</style>
<script>
$(document).ready(function(){
var a = $("#test").height;
if("a>200px"){
$("#test").hover(function(){
$("#para").addClass('active');
});
}
else {
("a>200px")
$("#test").mouseout(function(){
$("#para").addClass('try');
});
}
});
</script>
</head>
<body>
<div class="ads">
<div id="test">
<img src="img/img2.jpg"/>
</div>
<div id="contain">
<p id="para">what is HTml</p>
<div>
</div>
</body>
</html>
Up0Down

 
Explain your requirement clearly so that i can help you.Image Created0Down

By: [email protected] On: Sat Jan 21 11:04:09 IST 2017 Question Reputation0 Answer Reputation0 Belt Series Points0 0User Image
Are You Satisfied :0Yes0No
 
Hii it's very sort Explain so please first explain your requirement clearly may be i fix it for you.Image Created0Down

By: [email protected] On: Fri Feb 03 15:08:26 IST 2017 Question Reputation0 Answer Reputation0 Belt Series Points0 0User Image
Are You Satisfied :0Yes0No