Viewing 23 posts - 1 through 23 (of 23 total)
  • Author
    Posts
  • #530737

    Hey guys,
    I wanted to change the wpml language selector to language code. but i couldn’t really figure it out.

    Couple of issues came along as I followed the instructions on https://kriesi.at/support/topic/wpml-language-selector-in-text-format/#post-524326

    1. I don’t want a dropdown menu. I want DE | EN | FR next to each other
    2. As I added the following code, the full width sub menu showed some error. the position of the menu was hidden behind the header.

    add_action('after_setup_theme','avia_remove_main_menu_flags');
    function avia_remove_main_menu_flags(){
    	remove_filter( 'wp_nav_menu_items', 'avia_append_lang_flags', 20, 2 );
    	remove_filter( 'avf_fallback_menu_items', 'avia_append_lang_flags', 20, 2 );
    	remove_action( 'avia_meta_header', 'avia_wpml_language_switch', 10);
    }
    
    add_action('avia_meta_header', 'add_custom_content_to_header');
    function add_custom_content_to_header() {
            do_action('icl_language_selector');
    }

    3. as i added this css to change the position of the language selector it moved the language in the widget area.

    div#lang_sel_click {
        margin-top: 20px;
        margin-left: 203px;
    }

    See the images I provided to see what i want and how it looks now

    #531470

    Hey Arthith!

    please add the code from 2.) into your functions.php and let us know when you are done so we can check the issue on your website and inspect the elements.

    Best regards,
    Andy

    #531479

    okay done! :D also there was a small update regarding the position of the small bar with

    Über uns | Download | Kontakt | News and DE | FR | EN

    i want it in the same level as the main menu

    SCREENSHOT PREVIEW

    thanks a lot
    Cheers,
    Aathi

    #531486

    Hey!

    try this code in Quick CSS field:

    nav.sub_menu {
    display: flex;
    }
    

    Regards,
    Andy

    #531487

    looks better but there is still some behind the header

    #531498

    Hey!

    add this code as well:

    div#sub_menu1 {
    margin-top: 15px;
    }
    

    Cheers!
    Andy

    #531500

    nope. messed up the width of the whole website + the menu bar is just in middle of the page when u scroll u can see the text thorugh it

    SCREENSHOT

    #531526

    Hey!

    I can’t see your screenshot. Please use imgur.com or dropbox for it.

    Regards,
    Andy

    #531531

    SCREENSHOT

    • This reply was modified 9 years, 1 month ago by thatkidaathi.
    #531539

    Hey!

    could you provide us admin access, so we can take a closer look into it? Are we allowed to temporarily deactivate all your plugins? Post login details here as private reply.

    Best regards,
    Andy

    #531544

    Hello Andy,
    Yes admin info is below. yes the website is not online, so feel free. thank you

    #531552

    Hi!

    you did not add the code I provided you here, so I put it into Quick CSS and now it looks exactly as you want. Clear browser cache and hard refresh a few times.

    Cheers!
    Andy

    #531558

    No, I removed it coz it started to look like this.

    SCREENSHOT

    #531571

    Hi!

    it does not look for me like this when I add it. Did you clear browser cache and hard refreshed a few times before checking? Which browser and OS are you using?

    Cheers!
    Andy

    #531579

    Jap cleared the browser caching and hard refreshed. I’m using a mac with google chrome but also tested in on safari and firefox and i also tested it on another mac.

    make the browser smaller, so that you have to scroll through the page:
    visit the link i send u to see what i mean

    #531580

    I hope you also have a solution for the wpml plugin that it shows the languages as this: DE | FR | EN

    and a solution to get the small bar above the header on the same level of the main menu.

    Thank you.
    Cheers,
    Aathi

    #531590

    Hi!

    lets stick to one topic here please and open new tickets for different questions.

    It looks like this for me on Mac+Chrome:

    View post on imgur.com

    Cheers!
    Andy

    #531592

    Hi!

    When I am scrolling I think I see what you mean. Not sure why your menu bar is behaving weird. Try to delete all theme files via FTP completely before getting a fresh copy from your theme forest account. By the way: the new Enfold version is out (v3.4.1.) with lots of bug fixes and new features.

    Regards,
    Andy

    #532512

    Just updated the theme this morning to 3.4.1 and the error still occurs.
    The menu bar is still jumping once I scroll

    Thank you for your Help,

    Cheers,
    Aathi

    #532536

    Hey!

    did you follow my instructions from my previous post? simply overwriting or updating theme files does not help if there are corrupted theme files.

    Regards,
    Andy

    #532673

    Hey Andy,

    I did what you said, but I found out another way to resolve the issue.

    Just 2 more things and then I’m done ;)

    1. For some reason the menu point of the submenu are not aligned the same way like the rest of the website.
    Screenshot

    2. how can I hide the sub-menu for mobile and tablet? is there a easy css code?

    Thank you so much for your help!
    Aathi

    #532683

    Hi!

    Please add following code to Quick CSS

    @media only screen and (max-width: 990px) {
    #top .av-submenu-container { display: none !important; }}

    Then please go to Enfold/css folder and open shortcodes.css file and find following

    #top .av-submenu-container .container {
        padding: 0 !important;
    }

    and remove it

    Cheers!
    Yigit

    #532705

    Great thank you!

Viewing 23 posts - 1 through 23 (of 23 total)
  • The topic ‘WPML LANGUAGE SELECTOR TO LANGUAGE CODE’ is closed to new replies.