//global
var lang = 'e';
var loc = window.location.pathname;
loc = loc.toLowerCase();
if ((loc.indexOf('_c.') > 0)){
    lang = 'c';
}
else if(loc.indexOf('c_') == 1){
    lang = 'c';
}

//change languange function
function changeLang(){
    var go = '';
    var loc = window.location.pathname;
    loc = loc.toLowerCase();
    
        if ((loc.indexOf('_c.') > 0)){
            go = loc.replace('_c.', '_e.');
        }
        else if(loc.indexOf('c_') == 1){
            go = loc.replace('c_', 'e_');
        }
        else if((loc.indexOf('_e.') > 0)){
            go = loc.replace('_e.', '_c.');
        }
        else if(loc.indexOf('e_') == 1){
            go = loc.replace('e_', 'c_');
        }
        else{
            go = 'index_c.html';
        }
    
    

    window.location.href=go;
}

function sh(id){
    var div = document.getElementById(id);
    if (div){
        if (div.style){
            if (div.style.display == 'block'){
                div.style.display = 'none';
            }else{
                div.style.display = 'block';
            }
        }
    }
}

function showDiv(id){
    var div = document.getElementById(id);
    if (div){
        div.style.display = 'block';
    }
    var arrow = document.getElementById('fp_' + id);
    var arrow_o = document.getElementById('fp_' + id +'o');
    if (arrow && arrow_o){
        arrow.style.display = 'none';
        arrow_o.style.display = 'inline';
        /*if (arrow.src != '/images/fp_arrow_over.gif'){
            arrow.src = '/images/fp_arrow_over.gif';
        }*/
    }
}
function hideDiv(id){
    var div = document.getElementById(id);
    if (div){
        div.style.display = 'none';
    }
    var arrow = document.getElementById('fp_' + id);
    var arrow_o = document.getElementById('fp_' + id +'o');
    if (arrow && arrow_o){
        arrow.style.display = 'inline';
        arrow_o.style.display = 'none';
        /*if (arrow.src != '/images/fp_arrow.gif'){
            arrow.src = '/images/fp_arrow.gif';
        }*/
    }
}
