-
AuthorPosts
-
June 5, 2015 at 11:08 pm #455343
http://www.gravitygroms.com – when you arrive at the home page of this site there is another page highlighted?
I’ve tried this fix: https://kriesi.at/support/topic/anchor-link-causing-navigation-bar-to-highlight-the-wrong-link/
But nothing happens.
I’ve tried recreating the menu from scratch – and that doesn’t work either.I would imagine it has something to do with the #anchor tags in the menu? Or perhaps the – in the mega menu columns?
June 5, 2015 at 11:12 pm #455344I’ve tried this as well: .current_page_ancestor .avia-menu-fx, .current-menu-ancestor .avia-menu-fx, .current-menu-parent .avia-menu-fx {
display: block !important;
opacity: 1 !important;
visibility: visible !important;
}
.current-menu-item .avia-menu-fx { display: none; }Which just highlights the Camps instead… doesn’t work.
June 8, 2015 at 10:10 am #455867Hey!
Thank you for using Enfold.
Which menu items are you referring to? The home and camps menu is the same page. Why is that?
Cheers!
IsmaelJune 8, 2015 at 3:38 pm #456138When you first arrive at the page news photos and videos is selected instead of home.
June 8, 2015 at 4:07 pm #456160Hi!
It seems to be working fine on my end – http://i.imgur.com/zn9xhyV.png
Have you figured it out already?Best regards,
YigitJanuary 9, 2016 at 1:50 am #562259Hello!
It seams that I have the same issue on my page.
When the page loads up the first menu item in the header gets highlighted.
This menu item “PULMAVIDEOD” refers to the first anchor section on the page which is just a few scrolls below the front page image slider. All the other menu items/links serve the same purpose for other anchored color sections on the same page.
I added the following code to the functions.php to avoid the “previous menu item highlighted” issue
function add_custom_script(){ ?> <script> (function($){ $(window).load(function() { $(this).trigger('resize'); }); })(jQuery); </script> <?php } add_action('wp_footer', 'add_custom_script');
Is there something else I could add somewhere to make the first menu item not active until navigated on the respectful page?
Thank you for your efforts,
MikkJanuary 11, 2016 at 9:12 am #562990Hey!
What if you add another menu item called “Home”? Or try this in the functions.php file:
// fix menu active function add_custom_script(){ ?> <script> (function($){ var win = $(window), menu = $('#avia-menu'); remove = function() { if(win.scrollTop() == 0) { menu.find('.current-menu-item').removeClass('current-menu-item'); } else { return; } } win.scroll(function() { remove(); }); win.load(function() { remove(); }); })(jQuery); </script> <?php } add_action('wp_footer', 'add_custom_script');
Cheers!
IsmaelJanuary 11, 2016 at 2:09 pm #563123Hello!
A home button would solve it I guess but that is another button in the header menu and unfortunately if I add any more buttons the menu items and the logo will overlap each other when resizing the window to a smaller size. (Ipad screen seems to have the perfect size. Right on the border of collapsing into mobile view and desktop browser width so that the menu and logo will overlap. I had to resize my header fonts in order to avoid this).
At some point I might make an “about me” page to be the first one but at the moment this option does not suffice.
I tried pastin the above suggested code to my functions.php and enfold-functions.php both resulting in a blank white screen when dialing in my website or the wp-admin page in the address bar. I then had to go through an ftp client to delete the code in order to get my page functioning again. So either the above code has some mistakes in it or it doesn’t work.
One more thing to add to the header active not active issue:
The header menu items were at first marked as for example “#pulmavideod” to navigate to an anchor on the page. However when I’m on a subpage for example I have clicked on a portfolio item http://mikkrosin.ee/videod/pulmavideod/evelinjamartin then the header menu items won’t work when I’m on that page. Unless I make a custom link with the webpage in front like so: mikkrosin.ee/#pulmavideod. the menu items just do nothing but add “#pulmavideod” to the end of the address in the address bar like so http://mikkrosin.ee/videod/pulmavideod/evelinjamartin#pulmavideod.
So I could just make the header menu items with a custom link : mikkrosin.ee/#pulmavideod but then the whole header turns blue for some reason and doesn’t react to any hover effects. When the custom links are set as only “#pulmavideod” the menu items are white and on hover they turn blue(which is what I want but the links doesn’t work on subpages).
Any information to solve this is greatly appreciated and I’m very glad I have found such a theme with such great support.
Mikk
January 12, 2016 at 9:18 am #563755Hey!
Do you have another “add_custom_script” function in the functions.php file? Please change the function title to “add_custom_script_2” or something. Make sure that you copy the code directly from this forum, not from your email.
Best regards,
IsmaelJanuary 13, 2016 at 7:25 pm #564981Thank you!
That did the trick for the first menu being highlighted problem when first visiting the page.
Awsome theme!
January 14, 2016 at 4:55 am #565201 -
AuthorPosts
- You must be logged in to reply to this topic.