Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #348388

    Hi,

    ich habe für einen Kunden mit Enfold eine One-Page-Seite generiert: http://www.agenda-mensch.com
    (Diese Seite entspricht nicht mehr dem ursprünglichen Design, da der Kunde selbst sehr viel umgestellt hat)

    Für den Strich unterhalb des aktiven Menüs habe ich statt dem Standard ein Bild eingefügt.

    Nun habe ich folgendes Phänomen:
    Im Firefox funktioniert die Anzeige der aktiven Menüs ohne Probleme. Als generierten HTML-Code erhalte ich für den aktiven Menüpunkte folgendes:
    <li id=”menu-item-29″ class=”menu-item menu-item-type-custom menu-item-object-custom current_page_item menu-item-home menu-item-top-level menu-item-top-level-3 current-menu-item”>

    Im Chrome stattdessen den Code:
    <li id=”menu-item-29″ class=”menu-item menu-item-type-custom menu-item-object-custom current_page_item menu-item-home menu-item-top-level menu-item-top-level-3″>

    Hat wer eine Idee, warum dies hier anders ist und der aktive Menü in Chrome bzw IE nicht die Klasse current-menu-item erhält?

    Auf der Demo-Seite von kriesi.at funktioniert die One-Page-Seite auch in Chrome anstandslos. (Habe nichts anderes erwartet :-) )

    Thanks,
    Daniela

    #348591

    Hi Daniela!

    Thank you for using Enfold.

    Please try the following fix provided here: https://kriesi.at/support/topic/anchor-link-causing-navigation-bar-to-highlight-the-wrong-link/#post-268841

    If possible, please disable any cache or minifying plugins before testing the solution.

    Cheers!
    Ismael

    #349226

    Hi Ismael,

    Thanks for the fast solution.

    I changed the css and the code in avia.js.
    I deleted the cache and disabled the performance-plugin wp-rocket.

    It fixed the problem now in Google Chrome, but only for the logged-in-status.
    If I log out, it will not function anymore, even not in firefox.

    In firefox it works in the logged-out-status before changing the code. Now it only works in the logged-in-status.
    In IE it doesn’t work in the logged-in-status, nor in the logged-out-status.

    On the Ipad both items are marked – the previous and the actual one.

    Cheers!
    Daniela

    #349853

    Hi Daniela,

    Can you please create us a WordPress administrator account? post it here as a private reply.

    Regards,
    Josue

    #349992
    This reply has been marked as private.
    #350207

    Hi Daniela!

    What’s the username to log-in?

    Best regards,
    Josue

    #350513
    This reply has been marked as private.
    #351128

    Hi!

    The login credentials are not working. Please check.

    Regards,
    Ismael

    #351199
    This reply has been marked as private.
    #351694

    Hi!

    Did you remove the modifications on avia.js file? It’s not working even when I’m logged in. I noticed that you placed the helper-main-menu.php file on the child theme folder. What are the modifications that you added there?

    Cheers!
    Ismael

    #351812

    Hi Ismael,

    i see, it no longer works. I don’t know why.
    I changed the avia.js in the enfold-folder and i put a copy from it to the enfold-child-theme. There I generated a “js”folder and put the file in it.

    Helper-main-menu.php: I put the following code after do_action(‘ava_inside_main_menu’); echo ‘</nav>’; in it:

    echo “<div class=’add_text’></div>”;

    Thanks,
    Daniela

    #352371

    Hi!

    You have to dequeue or unregister the default avia.js file first. Did you add this code on functions.php? If not, please add it to enable the theme to recognize the avia.js file on the child theme.

    if(!is_admin()) add_action('wp_enqueue_scripts', 'avia_register_child_frontend_scripts', 100);
    function avia_register_child_frontend_scripts()
    {
    	$child_theme_url = get_stylesheet_directory_uri();
    	wp_dequeue_script('avia-default');
    
    	//register js
    	wp_register_script( 'avia-default-child', $child_theme_url.'/js/avia.js', array('jquery'), 1, true);
    	wp_enqueue_script( 'avia-default-child' );
    }

    Best regards,
    Ismael

    #352502

    Hi Ismael,

    No I did’nt dequeue or enque. Thank you very much for your hint and for the code. I put the code above into the function.php of the child-theme. My customer changed the navigation, so that not all menu-items link to a section of the page. The first two link to pages.
    Menu-item, which are pages get marked, menu-item, which are sections don’t get marked.

    Best regards,
    Daniela

    #352959

    Hi!

    I checked the site and current menu item marker is working for pages and section links. Please remove browser cache then reload the page a few times.

    Best regards,
    Ismael

    #353220

    Hi Ismael,

    due to problems with drag and drop in wordpress relating to theme enfold, I undid the changes in avia.js. I think there was a plugin-problem.
    I don’t know, why it now works. :)

    thank you very much for your support.
    I hope the problem is solved.

    Daniela

Viewing 15 posts - 1 through 15 (of 15 total)
  • The topic ‘One-Page-Site: Anzeige aktiver Menüpunkt funktioniert nicht in Chrome bzw. IE’ is closed to new replies.