Unable to hide class on click
Hi,
I am using the following to show and hide menu items on click, it shows the menu items when I click on the target however when I click a second time it does not hide the menu items again.
$(document).ready(function(){
$(".menu_sub_par_head").click(function(){
if ($('.menu_sub_head').is(":visible")) {
$(".menu_sub_head").hide();
}
else {
$(".menu_sub_head").show();
}
});
});
Any assistance would be appreciated.
Michael.