-
AuthorPosts
-
April 4, 2016 at 12:28 pm #607509
Hi! i would like my sidebar to nest at every 2nd level title, for example at “Leadership and Teams”, “Communication”, “Personal Effectiveness” and so on. Otherwise the menu is huge. I can´t manage to do this.
Any idea?
Thanx!
April 4, 2016 at 1:22 pm #607545Hi chaponnel!
Is this how you like the sidebar to look like? When user click on a menu item it shows the 2nd level elements? This requires custom css and jQuery coding and it takes some time… We are working on your ticket please wait while we update the custom code here soon.
Regards,
VinayApril 4, 2016 at 1:34 pm #607552Exactly! if the user click on, for example Communication, then it displays the submenu of Communication.
Thanx ill be waiting!
April 5, 2016 at 6:02 am #608038Hey!
This customisation requires much time and custom coding we are working on your ticket please wait while we update the results here.
Regards,
VinayApril 6, 2016 at 6:48 am #608699Hey!
Please add the below code in Enfold > General Styling > Quick CSS
.submenu-hide { display: none; } .submenu-show{ display: block!important; }
Add the below code in functions.php
// Custom submenu function custom_submenu(){ ?> <script> jQuery(window).load(function(){ var menu = jQuery('#menu-item-170'), subMenu = jQuery('#menu-item-170 .sub-menu li:has(ul)'); subMenu.children("ul").addClass("submenu-hide"); menu.find('li a').on('click', function(event) { var parent = jQuery(this).parent(); if (jQuery(this).parent().is('li:has(ul)')) { event.preventDefault(); parent.siblings().find('ul.submenu-show').removeClass('submenu-show'); parent.find('ul:first').toggleClass('submenu-show'); } }); }); </script> <?php } add_action('wp_footer', 'custom_submenu');
Note: We could not test this code on your site as we do not have the credentials. Please create a temporary user with ‘administrator’ role and share in private content with permission to deactivate all plugins and add custom code if necessary to help you resolve this issue. We will also need FTP access just in case.
Best regards,
Vinay- This reply was modified 8 years, 7 months ago by Vinay.
April 20, 2016 at 1:08 pm #618268Hello, sorry for the late reply, i´ve been out. I tried all of the above, not working.
I created an admin user, here´s the data and the ftp access, let´s see if you can manage it!
Thanx!
April 23, 2016 at 4:04 pm #620558Hey!
We would like to add the code but there is no functions.php file in the child theme. We can add it somewhere else but it’s more appropriate in the functions.php file. Create the file then add the code. We also noticed that the footer.php file is not updated. Please update that file as well.
Regards,
IsmaelApril 26, 2016 at 6:06 pm #622369Hi, i created the functions.php added the codes, but not working, what am i doing wrong?
April 29, 2016 at 2:57 pm #624524Hi,
I changed the code a bit, it should work now.
Best regards,
JosueMay 5, 2016 at 3:22 pm #627854Hey! thanx for your help, but the client didn´t like it, it was not what he was looking for, sorry.
One problem came up, now i can´t see any submenu, nor in the sidebar or in the main menu…I removed your code from the functions php so i don´t know what could have happened, it was ok before that code!
Thank you for your great support
May 5, 2016 at 3:31 pm #627860Hey!
You have this custom CSS code
ul.sub-menu { display: none !important; }
please remove it.
Best regards,
YigitMay 6, 2016 at 12:31 pm #628251I removed it but still not working…i can´t see the dropdowns in main menu nor the submenu in the sidebar
May 6, 2016 at 12:48 pm #628254Hey!
They show up fine on my end, attached a screenshot in private content field.
Please flush browser cache and refresh your page a few times – http://wiki.scratch.mit.edu/wiki/Hard_Refresh
Cheers!
YigitMay 6, 2016 at 2:42 pm #628311That was it! i was going crazy, now it works, thans so much for your help!
-
AuthorPosts
- The topic ‘Sidebar Menu nested at 2nd level’ is closed to new replies.