HTML-Code:
<html><head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<title>jQuery-Demo</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript">
$('document').ready(function () {
$('#nav span').click(function () {
$('#werbung').css({'display':'none'});
});
});
$('document').ready(function () {
setTimeout(function () {$('#werbung').css({'display':'none'})}, 3000);
});
</script>
<style type="text/css">
body{margin:0px; padding:0px;}
#werbung{width:640px; height:480px; border:1px solid #000; position:absolute; left:100px; top:150px; z-index:2;}
#nav{text-align:right;}
#nav span{cursor:pointer;}
</style>
</head>
<body>
<div id="werbung">
<div id="nav">
<span>close</span>
</div>
</div>
</body></html>