Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #789
    Profile photo of lucato
    lucato
    Participant

    Hi folks,

    My site is in two languages and I’m getting to translate a lot of things by using qtrasnlate plugin and changing the codes (texts) in several places, but I’m facing a hard time to translate a text within a .js (JavaScript) file.

    Just as a short explanations how do I get to translate in PHP files for example are this way:

    If I have a line:

    < ?php echo __('Copyright') ?>;

    I just need to change this way:

    < ?php echo __('Direitos AutoraisCopyright') ?>;

    Some other I had to create a variables (Example):
    $msgwelcome = __(‘Bem vindo a Welcome to ‘);

    So, I need a help for you guys that are programmers PHP, JAVA, and so on that have much more knowledge than I do as begginer. So I need to get to translate all that in inside .val () in the script bellow following the examples above in the PHP Language1Language2


    //login/logout functions
    $('#ss_account_submit').attr('disabled','disabled');
    $('#ss_account_submit').val('Password does not match.');

    $('.password').keyup(function(){
    if($("#ss_password_1").val() == $("#ss_password_2").val()){

    if($("#ss_password_1").val() == ''){
    return;
    }
    if($("#ss_password_2").val() == ''){
    return;
    }

    $('#ss_account_submit').removeAttr('disabled');
    $('#ss_account_submit').val('Create Account!');

    $('.password').removeClass('password_mismatch');
    $('.password').addClass('password_match');
    }else{
    $('#ss_account_submit').attr('disabled','disabled');
    $('#ss_account_submit').val('Password does not match.');

    $('.password').addClass('password_mismatch');
    $('.password').removeClass('password_match');
    }

    Let’s suppose I replace the code from:
    $(‘#ss_account_submit’).val(‘Password does not match.’);

    to code:
    $(‘#ss_account_submit’).val(‘Senha não confere‘);

    It shows on the button:
    Senha não confere

    Instead of showing only:
    Senha não confere (If in Brazilian Portuguese)
    Password does not match (If in English)

    As it does in PHP.

    Any help will be appreciated,
    thanks.

    #8035
    Profile photo of Leo
    Leo
    Participant

    Perhaps (since I can’t find it in my heart to shock everyone with a complete overhaul) I can FINALLY put in translation into the current version series. Would you like that? That way no hacking necessary.

    As we had discussed, perhaps you can send me your translation and I’ll make it a part of the downloadable package.

    Also did I send you the premium version yet as a trade? Let me know.

    #8036
    Profile photo of Imago Borealis
    Imago Borealis
    Participant

    @leo wrote:

    Perhaps (since I can’t find it in my heart to shock everyone with a complete overhaul) I can FINALLY put in translation into the current version series. Would you like that? That way no hacking necessary.

    As we had discussed, perhaps you can send me your translation and I’ll make it a part of the downloadable package.

    Also did I send you the premium version yet as a trade? Let me know.

    That’s good news! I am hoping you’re also going to code the infrastructure needed for having multilingual image metadata (title, description, keywords) in a way that the search works multilingual and Google sees it, too, for SEO/indexing purposes. I am looking forward to any new development in this area. 😀

    #8037
    Profile photo of lucato
    lucato
    Participant

    @leo wrote:

    Perhaps (since I can’t find it in my heart to shock everyone with a complete overhaul) I can FINALLY put in translation into the current version series. Would you like that? That way no hacking necessary.

    As we had discussed, perhaps you can send me your translation and I’ll make it a part of the downloadable package.

    Also did I send you the premium version yet as a trade? Let me know.

    Hi Leo, I’m sorry for my delay, but I was on vacations with my wife. :0)
    Man, I have sent you a sitemail (Check inbox PM) talking about it, have you received? Check that and we keep talking about it. Thanks.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.