function traduzir2(idioma){
     
    if(idioma == 'pt'){
        jQuery('body').show();
    }
    else{
        jQuery('body').translate(idioma,{
            start:     function(){  jQuery('body').hide() },
            complete:  function(){   jQuery('body').show(); initPaginationImagem();   },
            error:     function(){    jQuery('body').show()   }
        });
    }
}

function changeIdioma(idioma){
    
    var parametros = 'idioma='+idioma;

    jQuery.ajax({
        type : 'POST',
        url: '../administrador/modulo.outraslinguas/idioma.php',
        data: parametros,
        success: function(){
            window.location.reload();
        },
        error: function(){
            alert('Erro ao tentar processar a informação.');
        },
        complete: function(){
            //window.location.reload();
        }
    });
}
function traduzir(idioma){
    if(idioma == 'pt'){
        jQuery('body').show();
    }
    else{
        var arr = new Array(1);
        arr[0] = "Piedade";
        var arr2 = jQuery.map(arr,function(val,i){
            return(val + i);
        });

        var teste = jQuery('body').html();
        for(k=0 ; k < arr.length ; k++){
            teste2 = str_replace(arr[k],arr2[k],teste);
            teste = teste2;
        }

        jQuery('body').html(teste);
        //alert(jQuery('body').html());
        jQuery('body').translate(idioma,{
            start:     function(){  jQuery('body').hide() },
            complete:  function(){
                var teste = jQuery('body').html();
                for(k=0 ; k < arr.length ; k++){
                    teste2 = str_replace(arr2[k],arr[k],teste);
                    teste = teste2;
                }
                jQuery('body').html(teste);
                jQuery('body').show();
                initPaginationImagem();
            },
            error:     function(){    jQuery('body').show()   }
        });
    }
}



