Topbar language switcher

Hello,

How can I remove social icons from topbar and replace them with polylang language switcher.
I am using X theme (not PRO).

Thank you,

Palo

Hello Palo,

We need to adjust the template using the child theme.
Go to this theme folder on your installation and copy _topbar.php file
\wp-content\themes\x\framework\legacy\cranium\headers\views\global
Paste the copied file on the same folder on you child theme here:
\wp-content\themes\x-child\framework\legacy\cranium\headers\views\global
You might need to create the entire folder path. Open the copied file, on line 18 you will see this line of code:
<?php x_social_global(); ?>
Change that with your polylang language switcher code.

Hope this helps

I found that _topbar.php file but i dont know the language switcher code, where can i find it?

thank you,

Palo

Hey Palo,

Please check their documentation for that as Polylang is a third party plugin:

Hope this helps.

Ok, this helped a lot. One last question, how can i align the language switcher to right side of topbar.
I want topbar content with text on left and language switcher on right. Bestwould be if i can add text “Choose language” just before the language switcher.

thanks a lot,

Palo

Hey Palo,

Please try adding this code in X > Theme Options > CSS:

.x-topbar-inner select {
    float: right;
    margin: 2px 0;
}

Hope this helps.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.