Supportnet / Forum / Skripte(PHP,ASP,Perl...)
scroll-script geht mit i-frame nicht
Frage
Hi, ich hab ma ne frage an alle, ich hatte ein
scroll-script für einen i-frame gestaltet und es
ging am anfang auch aber das prog is mal abgestürzt
und seit ich es neu gemacht hab geht es nicht mehr,
vll sieht ja jemand woran es liegt, hier ist mal der
quelltext des kompletten seite:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>New Page 1</title>
<style type="text/css">
body { font-family:Verdana, Arial, Helvetica, sans-serif; font-size:10pt; }
a:link, a:visited, a:active {text-decoration:none; color:#cc3300; font-weight:plain;}
a:hover {text-decoration: underline; color:#cc3300; font-weight: plain;}
td { font-family:Verdana, Arial, Helvetica, sans-serif; font-size:10pt; }
</style>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//-->
</script>
</head>
<body bgcolor="#FFB1B1" text="#000000" link="#FFB1B1" vlink="#FFB1B1" alink="#FFB1B1" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<div id="Layer1" style="position:absolute; left:304px; top:139px; width:450px; height:41px; z-index:1"><img src="images/nav_oben.jpg" width="450" height="41"></div>
<div id="Layer2" style="position:absolute; left:128px; top:389px; width:450px; height:41px; z-index:1"><img src="images/nav_unten.jpg" width="450" height="41"></div>
<div id="Layer3" style="position:absolute; left:145px; top:352px; width:28px; height:30px; z-index:1"><a href="javascript:" onmouseover="myspeed=thespeed" onmouseout="myspeed=0"><img src="images/scroll_unten.gif" width="28" height="30" border=0
></a></div>
<div id="Layer4" style="position:absolute; left:709px; top:189px; width:28px; height:30px; z-index:1"><a href="javascript:" onmouseover="myspeed=-thespeed" onmouseout="myspeed=0"><img src="images/scroll_oben.gif" width="28" height="30" border=0
></a></div>
<div id="Layer5" style="position:absolute; left:308px; top:186px; width:266px; height:266px; z-index:1">
<ilayer name="nscontainer" width=266 height=200 clip="0,0,155,160">
<layer name="nscontent" width=266 height=200 visibility=hidden>
<iframe name="cwindow" width=266 height=200 src="http:\\[URL]www.yahoo.de[/URL]" scrolling="no" border="0" frameborder="0"></iframe>
</layer>
</ilayer></div>
<script>
var Hoffset=70 //Enter buttons' offset from right edge of window (adjust depending on images width)
var Voffset=80 //Enter buttons' offset from bottom edge of window (adjust depending on images height)
var thespeed=3 //Enter scroll speed in integer (Advised: 1-3)
var ieNOTopera=document.all&&navigator.userAgent.indexOf("Opera")==-1
var myspeed=0
var ieHoffset_extra=document.all? 15 : 0
var cross_obj=document.all? document.all.staticbuttons : document.getElementById? document.getElementById("staticbuttons") : document.staticbuttons
function iecompattest(){
return (document.compatMode!="BackCompat")? document.documentElement : document.body
}
function positionit(){
var dsocleft=document.all? iecompattest().scrollLeft : pageXOffset
var dsoctop=document.all? iecompattest().scrollTop : pageYOffset
var window_width=ieNOTopera? iecompattest().clientWidth+ieHoffset_extra : window.innerWidth+ieHoffset_extra
var window_height=ieNOTopera? iecompattest().clientHeight : window.innerHeight
}
function scrollwindow(){
window.cwindow.scrollBy(0,myspeed)
}
function initializeIT(){
positionit()
if (myspeed!=0){
scrollwindow()
}
}
if (document.all||document.getElementById||document.layers)
setInterval("initializeIT()",20)
</script>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="800" id="AutoNumber1" height="540">
<tr>
<td width="96" height="540" rowspan="3" background="images/line_1.jpg"> </td>
<td width="600" height="180" background="images/line_3.jpg" align="left" valign="bottom">
<img border="0" src="images/lines_oben.jpg" width="35" height="79"></td>
</tr>
<tr>
<td width="670" height="180">
<img border="0" src="images/center.jpg" width="701" height="212"></td>
</tr>
<tr>
<td width="670" height="180" background="images/line_2.jpg" valign="top">
<img border="0" src="images/lines_unten.jpg" width="35" height="79"></td>
</tr>
</table>
</body>
</html>

