Difference between revisions of "Template:AFCM-Egypt"

Line 19: Line 19:
 
function menu_functionality() {
 
function menu_functionality() {
  
//when clicking on a "menu_button", it will change the "+/-" accordingly and it will show/hide the corresponding submenu
+
$(".menu_button").click(function(){
+
 
 +
 
 +
$( '.menu_button' ).hover(
 +
        function(){
 +
            $(this).children('.submenu_wrapper').slideDown(200);
 +
        },
 +
        function(){
 +
            $(this).children('.submenu_wrapper').slideUp(200);
 +
        }
 +
    );
 +
 
 +
 
 +
 
 +
 
 +
 
 +
 
  
// add or remove the class "open" , this class holds the "-"
 
$(this).children().toggleClass("open");
 
// show or hide the submenu
 
$(this).next('.submenu_wrapper').fadeToggle(400);
 
});
 
  
 
// when the screen size is smaller than 800px, the display_menu_control button appears and will show/hide the whole menu
 
// when the screen size is smaller than 800px, the display_menu_control button appears and will show/hide the whole menu

Revision as of 20:41, 7 August 2017