How to deal with translation by code?

New Member
6 0 0



I have changed theme code so much so I think translation app is not suitable for my web-page.

I have written code for translation.


<div data-tl="example">example</div>




$.lang = {};

$ = {

"example" :"ejemplo",



function setLanguage(currentLanguage) {

$('[tl]').each(function() {
var $this = $(this);






I have noticed that most of web cralwers get page data before web page runs Javascript which means my code causes 'duplicated content' problem.


I would like to know if there is any way to solve my problem.

Could you please help me?


Thank you.