Support » Plugin: Polylang » Custom language Switcher – how to remove bullet

  • Resolved mountain_spring


    So I made a custom images to be language switcher in a way that I put them in flags folder and renamed them in en_us.png and so.

    I’ve used the following code to display the image link in header

    <div id="lang"><?php pll_the_languages(array('hide_current'=>1, 'show_flags'=>1, 'show_names'=>0));?></div>

    The problem is that I don’t know how to remove bullet from link. :-/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Chouby


    This is a wrong usage of the function. You must write:

    <ul id="lang"><?php pll_the_languages(array('hide_current'=>1, 'show_flags'=>1, 'show_names'=>0));?></ul>

    Of course you can include this in a div if you want.
    Then in your css:

    #lang {list-style-type:none}



    Great, thanks a lot. ๐Ÿ˜‰



    Hm, since I’ve renamed my english and other language flags to get something else to be images for the switcher, now I’ve also lost those flags in wordpress admin panel. :-/

    Is there a way to get only language switcher url?

    Something like

    <a href="CODE TO GET URL HERE"><img src="images/header_en.png"></a>

    Sorry, I’m not into php. :-/

    Plugin Author Chouby


    The best way to use custom flags is to do as described in the documentation:

    Can I use my own flags for the language switcher ?
    Yes. You have to use PNG or JPG files and name them with the WordPress locale. For example, en_US.png. Then upload these files in the /wpยญcontent/polylang/ directory (create the directory if it does not exist). Don’t use the /polylang/flags/ directory as your files would be removed when automatically updating the plugin.

    This modifies only the flags of the language switcher, not on the admin side.



    In the other words RTFM. ๐Ÿ˜€ ๐Ÿ˜‰

    Great, problem solved, thanks again. ๐Ÿ˜‰

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Custom language Switcher – how to remove bullet’ is closed to new replies.