Kopieren Sie den Code -Code wie folgt:
<html>
<kopf>
<meta http-äquiv = "content-type" content = "text/html; charset = gb2312">
<titels> Web -schwimmender Werbecode mit einer geschlossenen Taste </title>
</head>
<body>
<div id = "img" style = "Position: absolut; links: 311; oben: 815; Sichtbarkeit: versteckt; erval = setInterval ('ChangePos (), Delay)" Align = "Right">
<A href = "#" target = "_lank"> <img src = "picture path" online "online =" return imgzoom (this, 600); Style = "Cursor: Zeiger;"/> </a>
<span style = "Cursor: Hand; Farbe: Rot; Schriftgewicht: BOLD" Onclick = "ClearInterval (Intervall); img.style.visibility = 'Hidden'"> x </span>
</div>
<script Language = javaScript src = ff.js>
</script>
</body>
</html>
ff.js Code
Kopieren Sie den Code -Code wie folgt:
var xpos = 20;
var ypos = document.body.clitingHeigh;
var Schritt = 1;
var delay = 30;
var Höhe = 0;
var Hoffset = 0;
var kriegswoffset = 0;
var yon = 0;
var xon = 0;
var pause = true;
var intervall;
img.style.top = ypos;
Funktion Changepos () {{)
width = document.body.clientwidth;
Höhe = document.body.clitingHeight;
Hoffset = img.offseteight;
Woffset = img.offsetwidth;
img.style.left = xpos + dcument.body.scrollleft;
img.style.top = ypos + dcument.body.scrolltop;
if (yon) {
ypos = ypos + Schritt;
}
anders {
ypos = ypos -step;
}
if (ypos <0) {
yon = 1;
Ypos = 0;
}
if (ypos> = (Höhe -host) {{{{{{{{{{{{{{{{
yon = 0;
ypos = (Höhe -hoffset);
}
if (xon) {
XPOS = XPOS + STEP;
}
anders {
Xpos = xpos -step;
}
if (xpos <0) {
xon = 1;
Xpos = 0;
}
if (xpos> = (width -Woffset) {{{{{{{
xon = 0;
XPOS = (Breite -Woffset);
}
}
Funktion start () {
img.style.visibility = "sichtbar";
Interval = setInterval ('changepos (), delay);
}
Start ();