0

Help me please

i have created a dropdn menu, when a user click a icon..here is ts jquery $("#icon").click(function(){ $("nav>ul").children().slideToggle(500); /* when a icon is clicked, the element below the drop down( i.e video), moves down, its margin-top changes from 5px to 50px as shown below*/ $("video").css("margin-top","50px"); }); the problem is when i click the icon again, to slide up the dropdown menu, the video element stays in the margin-top of 50px, i want it to go back to 5px...how ts done?

19th Jun 2017, 2:40 PM
Kelvine De Danielo
Kelvine De Danielo - avatar
1 Antwort