//var hotkeyelement = null;
//var hotkeyproduct = false;
//var keyword = null;

$(function() {
    //$('ul.menu').menu();
//    keyword = $.getQuerystring({ id: "k" });
//    hotkeyproduct = $.getQuerystring({ id: "p", defaultvalue: false });
//    $(document).bind('keypress', 'return', function() {
//        if (hotkeyelement) { keyword = $(hotkeyelement).val(); }
//        if (keyword && keyword != null && keyword != '' && keyword != "null" && keyword != "undefined") {
//            var url = 'Search.aspx?k=' + keyword;
//            if (hotkeyproduct)
//                url += '&p=1';
//            window.top.location = url;
//        }
//        return false;
//    });
});

//function resetKeyword(searchbox, defaulttext) {
//    if (searchbox.value == "") {
//        searchbox.value = defaulttext;
//    } else if (searchbox.value == defaulttext) {
//        searchbox.value = "";
//    }
//}
$(document).ready(function () {
    //Zet eerst alle product links zover naar beneden als dat ze hoog zijn
    $(".product-links").each(function () {
        var h = $(this).innerHeight();
        $(this).stop().animate({ bottom: '-' + h + 'px' }, 1);
    });
    //Daarna bij een mouseover (of eigenlijk -enter) de productlinks naar boven animeren
    $(".threeblocksplaceholder .block").each(function () {
        $(this).mouseenter(function () {
            $(this).children().children(".product-links").stop().animate({ bottom: '0px' }, 300);
        });
        //en bij een mouseleave weer naar beneden zo ver als ze hoog zijn
        $(this).mouseleave(function () {
            var h = $(this).children().children(".product-links").innerHeight();
            $(this).children().children(".product-links").stop().animate({ bottom: '-' + h + 'px' }, 500);
        });
    });
});

