
//***---
var J = jQuery.noConflict();
//***---
J.extend({
    //***---
    getUrlVars: function(){
        //***---
        var vars = [], hash;
        var hashes = window.location.href.slice(window.location.href.indexOf("?") + 1).split("&");
        //***---
        for(var i = 0; i < hashes.length; i++) {
            //***---
            hash = hashes[i].split('=');
            vars.push(hash[0]);
            vars[hash[0]] = hash[1];
            //***---
        }
        //***---
        return vars;
        //***---
    },
    getUrlVar: function(name){
        //***---
        return J.getUrlVars()[name];
        //***---
    }
    //***---
});
//***---

//***---
J(document).ready(function() {
    //***---
    //***---
    var byName = J.getUrlVar("ID");
    //***---
    /**/
    //***---
    J("#code").each(function(){
      if(this.value==''){this.value='Κωδικός'}
    });
    //***---
    J("#code").focus(function(){
      if(this.value=='Κωδικός'){this.value=''}
    });
    //***---
    J("#code").blur(function(){
      if(this.value==''){this.value='Κωδικός'}
    });
    //***---

    //***---
    J("#phone").each(function(){
      if(this.value==''){this.value='Αριθμός'}
    });
    //***---
    J("#phone").focus(function(){
      if(this.value=='Αριθμός'){this.value=''}
    });
    //***---
    J("#phone").blur(function(){
      if(this.value==''){this.value='Αριθμός'}
    });
    //***---
    /**/
    //***---

    //***---
    if (byName !== null) var exploded = byName.split("#");
    if (exploded[1] == "anch2" && byName !== null) {
        //***---
        toggle_layer("mylayer_2");
        J.scrollTo("#accLink2");
        //***---
    } else if (exploded[1] == "anch1" && byName !== null) {
        //***---
        toggle_layer("mylayer_1");
        toggle_layer("mylayer_2");
        J.scrollTo("#accLink1");
        //***---
    } else if (exploded[1] == "anch3" && byName !== null) {
        //***---
        toggle_layer("mylayer_3");
        J.scrollTo("#accLink3");
        //***---
    }else if (exploded[1] == "anch4" && exploded[0] == "YUPT6QH506MLcpKQ"  && byName !== null) {
        //***---
        toggle_layer("mylayer_4");
        J.scrollTo("#accLink4");
        //***---
    }

    //***---
    //***---
});
//***---

//***---
function gotoanchor(anchor) {
    //***---
    var byName = J.getUrlVar("ID");
    //***---
    if (byName !== null) var exploded = anchor.split("#");
    //***---
    if (exploded[1] == "anch2" && byName !== null) {
        //***---
        toggle_layer("mylayer_2");
        J.scrollTo("#accLink2");
        //***---
    } else if (exploded[1] == "anch3" && byName !== null) {
        //***---
        toggle_layer("mylayer_3");
        J.scrollTo("#accLink3");
        //***---
    }
    //***---
}
//***---
