var timeout;
function toogle(what, ms) {
    if (ms == null) {
        ms = 2000;
    }
    timeout = setTimeout(
        function() {
            if ($(what).html() != '') {
                $(what).fadeOut(ms);
            } else {
                alerts();
            }
        }, ms
    )
}



function fadeOut(what, ms) {
    if (ms == null) {
        ms = 2000;
    }
    $(what).click(function () {
      $(what).fadeOut("slow");
    });
}


function zobrazPrispevek(field) {
     if ($(field).is(':visible')) {
        $(field).slideUp("slow");
     } else {
        $(field).slideDown("slow");
     }
}
