Tagged: enfold, language switcher, multilingual, wpml
-
AuthorPosts
-
September 3, 2018 at 9:21 am #1004820
Dear Support-Team,
I would like to adjust the max-length of the WPML language switcher dropdown menu on my Enfold page.
So far i tried to add the following CSS to the «Additional CSS»-section under the Language switcher options:
li.wpml-ls-menu-item ul li a {
width: auto;
}I also added the following CSS code to the Enfold Quick CSS section:
.menu-item-language .dropdown-menu {
min-width: auto !important;
}Unfortunately it didn’t change anything.
Thanks for your reply!- This topic was modified 6 years, 2 months ago by AleschJ.
September 3, 2018 at 11:26 am #1004866Hey AleschJ,
Are you looking to make it wider? If so then you can try this in Quick CSS:
li.menu-item-language { padding: 0 10px; }
Adjust the values to your liking.
Best regards,
RikardSeptember 3, 2018 at 11:43 am #1004883Hi Rikard
Thanks for your answer.
I would like to make the dropdown menu less wide, so that the length is equal to the flag.
Best regards
AleschJSeptember 3, 2018 at 11:52 am #1004893Hi,
Thanks for the clarification. Please try this instead:
li.menu-item-language .sub-menu { width:auto; }
Best regards,
RikardSeptember 3, 2018 at 12:22 pm #1004913Hi Rikard
It looks much better, but the flag is now a bit squeezed. Is there a solution that the flag could appear in it’s original size?
Thanks a lot!
AleschJSeptember 3, 2018 at 1:41 pm #1004948Hi AleschJ,
It looks like you have removed the flag and used the text option instead? Please put the flag back, otherwise we can’t give you accurate CSS.
Best regards,
RikardSeptember 3, 2018 at 5:21 pm #1005072Hi Rikard
Sorry for that, I put back the flags. Thanks a lot for your good and fast support.
Best regards
AleschJSeptember 3, 2018 at 6:00 pm #1005098Hi AleschJ,
Here is the code you can put in Enfold > General Styling > Quick Css, if it does not work, put into themes/enfold/css/custom.css
.wpml-ls-menu-item .wpml-ls-flag { width: 24px; height: 16px; } li.menu-item-language > a { padding: 0 20px; }
If you need further assistance please let us know.
Best regards,
VictoriaSeptember 4, 2018 at 9:08 am #1005326Hi Victoria
Thanks for the code, this works perfectly!
Best regards
AleschJSeptember 4, 2018 at 12:59 pm #1005506Hi,
Great, glad you got it working :-)
Please let us know if you should need any further help on the topic or if we can close it.
Best regards,
RikardSeptember 5, 2018 at 7:33 am #1005898This reply has been marked as private.September 5, 2018 at 9:14 am #1005926 -
AuthorPosts
- The topic ‘Adjust length of WPML language switcher’ is closed to new replies.