﻿function fix_greek_links() {
    var mycount;
    mycount = document.getElementsByTagName('a').length;
    for (i = 0; i < mycount; i++) {
        var mylink = document.getElementsByTagName('a')[i];
        if (mylink.href != "#" && mylink.href != "") {
            try { mylink.href = decodeURI(mylink.href);  }
            catch (err) { }
        }
    }
}

function querySt(ji) {
    hu = window.location.search.substring(1);
    gy = hu.split("&");
    for (i = 0; i < gy.length; i++) {
        ft = gy[i].split("=");
        if (ft[0] == ji) {
            return ft[1];
        }
    }
    return '';
}

function resizeFrame(f) {
    f.style.height = f.contentWindow.document.body.scrollHeight + "px";
}

jQuery(document).ready(function () {
    fix_greek_links();
    if (querySt('id') == '') return;

    jQuery('.pager a').each(function (ordernum, link) {
        var jLink = jQuery(link);
        if (jLink.html() == (parseInt(querySt('id'))+1)+'')
            jLink.addClass('selected');
    });
});



