//var langset=getLanguage();

function getUTCFormat(aDate) {
    var theDate = aDate ? aDate : new Date();
    try {
        year = theDate.getYear();
    }
    catch (err) {
        theDate = new Date();
    }
    year = theDate.getYear();
    month = theDate.getMonth();
    day = theDate.getDate();
    hrs = theDate.getHours();
    min = theDate.getMinutes();
    sec = theDate.getSeconds();
    return Date.UTC(year, month, day, hrs, min, sec);
}

var SessionID = "";
var SessionDate = null;
SessionID = getCookie("SessionID");
SessionDate = getCookie("SessionDate");

try {
    if (SessionDate == null) {
        SessionDate = new Date();
        SessionID = getUTCFormat(SessionDate);
    }
    //year = SessionDate.getYear();
}
catch (err) {
    SessionDate = new Date();
    SessionID = getUTCFormat(SessionDate);
}


SessionDate = (SessionDate == null) ? new Date() : Date.parse(SessionDate);
SessionID = getUTCFormat(SessionDate);
setCookie("SessionID", SessionID, 5 * 60 * 1000);
setCookie("SessionDate", SessionDate, 5 * 60 * 1000);




