Tagged: Language, LayerSlider, polylang
-
AuthorPosts
-
March 1, 2022 at 10:06 am #1342673
Hi There
What i did was creating the pages in DE and in EN. For this i used the WPML plugin and translated the pages manually.
Now i copied the LayerSlider ‘Startseite’ and named it ‘Home EN’ and translated the text on the first slide manually aswell.When I’m on the english page builder for the page Home i inserted the ‘Home EN’ LayerSlider but it simply wont translate to english in the FrontEnd Preview.
What did i do wrong there?
Kind Regards,
Oliver- This topic was modified 2 years, 8 months ago by attifilm.
March 1, 2022 at 10:38 am #1342682Hey attifilm,
Thank you for the inquiry.
You will have use the WPML String Translation in order to translate the text or strings in the layer slider. Please check this documentation for more info about the slider translation.
Best regards,
IsmaelMarch 3, 2022 at 5:31 pm #1343034March 4, 2022 at 4:45 pm #1343164Hi Ismael and all
So what i did now was to delete the copy of the layerslider. I just have one now for the page “startseite” and “home”.
I went to Sprachen / Übersetzungen von ZeichenkettenIn there i translated the text manually.
It translated the first and the last part of the slider but not the word “bei” to “to”.
So now im stuck here.Andy ideas?
Regards,
OliverMarch 5, 2022 at 9:03 pm #1343290Hi,
Thanks for your patience, I don’t have a lot of experience with Polylang so I added this script into your functions.php to change bei ▸ to on the English pagefunction layer_slider_translation() { ?> <script> (function($){ $(window).load(function(){ setInterval(function () { $('html[lang="en-US"] #layer_slider_1 h6').text(function(index, text) { return text.replace('bei', 'to'); }); }, 500); }); })(jQuery); </script> <?php } add_action('wp_footer', 'layer_slider_translation');
please clear your browser cache and check.
I recommend using a child theme and moving this to it so it won’t be lost in updates.Best regards,
MikeMarch 18, 2022 at 10:14 am #1345028Hi Mike
Sorry for the late reply.
It works perfectly! Thank you very muchKind Regards,
OliverMarch 18, 2022 at 3:01 pm #1345094Hi,
Great, I’m glad that Mike could help you out. Please let us know if you should need any further help on the topic or if we can close it.
Best regards,
RikardApril 8, 2022 at 11:57 am #1347694Hi Rikard
Yes you can close it. Thank youApril 8, 2022 at 12:57 pm #1347706Hi,
Glad we were able to help, if you have any further questions please create a new thread and we will gladly try to help you. Thank you for using Enfold.Best regards,
Mike -
AuthorPosts
- The topic ‘LayerSlider Front End Problem’ is closed to new replies.