Ich habe bla mit dem code aus dem div ersetzt. Also das div in den p tag. Aber nun wird garnichts mehr angezeigt, sondern ein weißes fenster.
HTML:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
<title>tutorials.de | demo_fixxxxxi</title>
<script type="text/javascript">
<!--
function swap() {
var numtext=2;
rndtxt = new Array("<p><p style="background: transparent url(images/blase.gif) no-repeat scroll left -20px; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;"><h2 style="margin: 0pt 0pt 0pt 12px; padding: 12px 12px 0pt 24px; background: transparent url(images/symb_win.png) no-repeat scroll 0pt 11px; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;"><a href="javascript:close('faqkontakt');" style="float: right;"><img src="images/info_1.gif" onmouseover="this.src='images/info_2.gif'" onmouseout="this.src='images/info_1.gif'" alt="Schliessen" style="border: 0pt none ;"></a><a style="color: rgb(51, 51, 51); text-decoration: none; font-family: Arial,sans-serif; font-style: normal; font-variant: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; font-weight: bold;">Test</a></h2><p style="margin: 0pt 0pt 0pt 12px; padding: 4px 12px 0pt 0pt; background: transparent url(images/blase.gif) no-repeat scroll right -30px; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;"><a href="http://www.test.de" target="_blank" style="color: rgb(51, 51, 51); text-decoration: none; font-family: Arial,sans-serif; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10px; line-height: normal; font-size-adjust: none; font-stretch: normal;">test test test test test test test!<br></a></a></p><p style="margin: 0pt; padding: 0pt; background: transparent url(images/blase.gif) no-repeat scroll left bottom; height: 28px; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;"> </p>
<\/p>", "<p>blubb<\/p>");
x=(Math.floor(Math.random()*numtext));
randomtext=(rndtxt[x]);
document.getElementById("txtBox").innerHTML = randomtext;
}
window.onload = function(){
swap();
}
//-->
</script>
</head>
<body >
<div id="txtBox"></div>
</body>
</html>