Commit 66d7c5e8 authored by Ad Schellevis's avatar Ad Schellevis

(MVC) hide empty menu options

parent 5062fb28
...@@ -44,6 +44,13 @@ ...@@ -44,6 +44,13 @@
$("a[class='showhelp']").click(function () { $("a[class='showhelp']").click(function () {
$("*[for='" + $(this).attr('id') + "']").toggleClass("hidden show"); $("*[for='" + $(this).attr('id') + "']").toggleClass("hidden show");
}); });
// hide empty menu items
$('#mainmenu > div > .collapse').each(function(){
if ($(this).children().length == 0) {
$("#mainmenu").find('[href="#'+$(this).attr('id')+'"]').remove();
}
});
}); });
</script> </script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment