Home › Forums › SKT Full Width Forum › Menu Collapsed Menu by Default
- This topic has 5 replies, 3 voices, and was last updated 8 years, 10 months ago by Muhammad Zakir.
-
AuthorPosts
-
December 16, 2014 at 2:32 am #2918
Good Evening,
I would like to have the menu collapsed by default and then clicked to expand. I read through older post and found the same question but the solution isn’t working for me. I add the line of code jQuery( “.show_hide_header” ).hide(); and the menu collapse/expand button stops working. Has something changed ? Should the instructions in older post still work?
Thank you in advance
December 16, 2014 at 6:20 am #2921Hi,
hide navigation default in full width pro:
find custom-functions.php file in inc folder of your theme directory
Path: /wp-content/themes/skt_full_width_pro/inc
open custom-functions.php and add this code after line no. 29
jQuery(‘.show_hide_header’).css(‘display’,’none’);That’s it.
Regards,
ShriDecember 16, 2014 at 2:21 pm #2926Good Morning and Thank YOu for the quick reply,
I inserted the code as suggested but the menu is still expanded at start up and with the code in place the collapse function stops working. Below is were I inserted the code:
add_action(‘wp_head’,’hook_custom_javascript’);
function hook_custom_javascript(){?>
<script>
jQuery(document).ready(function() {
jQuery(‘.show_hide_header’).css(‘display’,’none’);
jQuery(“#header-bottom-shape”).click(function(){
if ( jQuery( “.show_hide_header” ).is( “:hidden” ) ) {
jQuery( “.show_hide_header” ).slideDown(“slow”);
} else {
jQuery( “.show_hide_header” ).slideUp(“slow”);
}
jQuery( this ).toggleClass(‘showDown’);
});
jQuery( “#site-nav li:last” ).addClass(“noBottomBorder”);
jQuery( “#site-nav li:parent” ).find(‘ul.sub-menu’).parent().addClass(“haschild”);
});
</script>
Anything else I can try or look at?
Thank you again for your help
http://www.culpeppersteakhouse.com
December 17, 2014 at 10:53 am #2932Hi,
If you can send us WordPress admin details via email: [email protected] we will check this for you.
Also i guess the inverted commas are not properly done. May be that is an issue. Well anyways just send us admin details we will take care of it.
Regards,
ShriDecember 17, 2014 at 2:19 pm #2934Thank you Shri,
I tested your suggestion and used the following code and all is working great.
jQuery(“.show_hide_header”).css(“display”,”none”);
This made the webpage on the pc just the way I was hoping but on iOS devices the menu disappeared, so I had to go back to standard menu. I’ll email admin details to you.
Thank you again
December 7, 2015 at 2:06 pm #16073Hi Shri,
I use same the code that you suggest, it’s work.
But i have problem with responsive layout for mobile, the button expand menu do not show, how to fixed ?
Thank you
-
AuthorPosts
- You must be logged in to reply to this topic.