Can someone assist me in identifying the issue with this code? I am attempting to implement a basic slideToggle functionality! Here is my initial attempt:
$("..").slideToggle(..,..,..)
This is what my current code looks like:
My code:
$(document).ready(function () {
$("#Layer13copy2").click(function () {
$("#toggle").animate({ height: 'toggle' });
});
});
#Layer13copy2 {
left: 13.85%;
top: 398px;
position: absolute;
width: 892px;
height: 37px;
z-index:5;
background:url('../images/slidet.png') 45%;
background-repeat:no-repeat;
background-size:101.4% 101%;
}
#toggle {
z-index: 4;
background-color: #3a97b1;
display: block;
left: 13.85%;
top: 39.37%;
position: absolute;
width: 71.95%;
height: 17%;
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script>
<div id="Layer13copy2"></div>
<div id="toggle"></div>