-
AuthorPosts
-
November 5, 2015 at 12:53 pm #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
November 6, 2015 at 3:42 pm #531470Hey 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,
AndyNovember 6, 2015 at 3:54 pm #531479okay 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
thanks a lot
Cheers,
AathiNovember 6, 2015 at 4:01 pm #531486Hey!
try this code in Quick CSS field:
nav.sub_menu { display: flex; }
Regards,
AndyNovember 6, 2015 at 4:02 pm #531487looks better but there is still some behind the header
November 6, 2015 at 4:13 pm #531498Hey!
add this code as well:
div#sub_menu1 { margin-top: 15px; }
Cheers!
AndyNovember 6, 2015 at 4:15 pm #531500nope. 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
November 6, 2015 at 4:53 pm #531526Hey!
I can’t see your screenshot. Please use imgur.com or dropbox for it.
Regards,
AndyNovember 6, 2015 at 4:56 pm #531531- This reply was modified 9 years, 1 month ago by thatkidaathi.
November 6, 2015 at 5:03 pm #531539Hey!
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,
AndyNovember 6, 2015 at 5:09 pm #531544Hello Andy,
Yes admin info is below. yes the website is not online, so feel free. thank youNovember 6, 2015 at 5:17 pm #531552Hi!
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!
AndyNovember 6, 2015 at 5:21 pm #531558No, I removed it coz it started to look like this.
November 6, 2015 at 5:33 pm #531571Hi!
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!
AndyNovember 6, 2015 at 5:38 pm #531579Jap 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 meanNovember 6, 2015 at 5:40 pm #531580I 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,
AathiNovember 6, 2015 at 5:47 pm #531590Hi!
lets stick to one topic here please and open new tickets for different questions.
It looks like this for me on Mac+Chrome:
Cheers!
AndyNovember 6, 2015 at 5:49 pm #531592Hi!
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,
AndyNovember 9, 2015 at 12:36 pm #532512Just updated the theme this morning to 3.4.1 and the error still occurs.
The menu bar is still jumping once I scrollThank you for your Help,
Cheers,
AathiNovember 9, 2015 at 1:19 pm #532536Hey!
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,
AndyNovember 9, 2015 at 3:48 pm #532673Hey 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.
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!
AathiNovember 9, 2015 at 3:52 pm #532683Hi!
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!
YigitNovember 9, 2015 at 4:18 pm #532705Great thank you!
-
AuthorPosts
- The topic ‘WPML LANGUAGE SELECTOR TO LANGUAGE CODE’ is closed to new replies.