jQuery.fn.delay = function(time,func){
    return this.each(function(){
        setTimeout(func,time);
    });
};


$(document).ready(function() {
	var div = $('#alert.ok');
	div.delay(3000, function() { div.fadeOut(); });
});
