<P> <SCRIPT language=JavaScript1.2><BR><!-- innen<BR>/*<BR>Letöltve a ThomasWebMűhely javascript archívumából:<BR><A href="http://twm.faxunil.hu/muhely/">http://twm.faxunil.hu/muhely/</A><BR>*/ var snowsrc="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" // a hópehely kép url-je</P> <P> var no = 10; // a hópelyhek száma a lapon</P> <P> var ns4up = (document.layers) ? 1 : 0;<BR> var ie4up = (document.all) ? 1 : 0;<BR> var ns6up = (document.getElementById&&!document.all) ? 1 : 0;</P> <P> var dx, xp, yp;<BR> var am, stx, sty;<BR> var i, doc_width = 800, doc_height = 600; // képernyő méretek<BR> <BR> if (ns4up||ns6up) {<BR> doc_width = self.innerWidth;<BR> doc_height = self.innerHeight;<BR> } else if (ie4up) {<BR> doc_width = document.body.clientWidth;<BR> doc_height = document.body.clientHeight;<BR> }</P> <P> dx = new Array();<BR> xp = new Array();<BR> yp = new Array();<BR> am = new Array();<BR> stx = new Array();<BR> sty = new Array();<BR> <BR> for (i = 0; i < no; ++ i) { <BR> dx[i] = 0;<BR> xp[i] = Math.random()*(doc_width-50);<BR> yp[i] = Math.random()*doc_height;<BR> am[i] = Math.random()*20;<BR> stx[i] = 0.02 + Math.random()/10;<BR> sty[i] = 0.7 + Math.random();<BR> if (ns4up) {</P> <P> document.write("<layer name=\"dot"+ i +"\" left=\"15\" top=\"15\" visibility=\"show\"><img src='"+snowsrc+"' border=\"0\"></layer>");</P> <P> } else if (ie4up||ns6up) {</P> <P> document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><img src='"+snowsrc+"' border=\"0\"></div>");</P> <P> }<BR> }<BR> <BR> function snowNS() {</P> <P> for (i = 0; i < no; ++ i) {<BR> yp[i] += sty[i];<BR> if (yp[i] > doc_height-50) {<BR> xp[i] = Math.random()*(doc_width-am[i]-30);<BR> yp[i] = 0;<BR> stx[i] = 0.02 + Math.random()/10;<BR> sty[i] = 0.7 + Math.random();<BR> doc_width = self.innerWidth;<BR> doc_height = self.innerHeight;<BR> }<BR> dx[i] += stx[i];<BR> document.layers["dot"+i].top = yp[i];<BR> document.layers["dot"+i].left = xp[i] + am[i]*Math.sin(dx[i]);<BR> }<BR> setTimeout("snowNS()", 10);<BR> }</P> <P> function snowIE_NS6() { // IE and NS6 funkció<BR> for (i = 0; i < no; ++ i) {<BR> yp[i] += sty[i];<BR> if (yp[i] > doc_height-50) {<BR> xp[i] = Math.random()*(doc_width-am[i]-30);<BR> yp[i] = 0;<BR> stx[i] = 0.02 + Math.random()/10;<BR> sty[i] = 0.7 + Math.random();<BR> doc_width = ns6up?window.innerWidth : document.body.clientWidth;<BR> doc_height = ns6up?window.innerHeight : document.body.clientHeight;<BR> }<BR> dx[i] += stx[i];<BR> if (ie4up){<BR> document.all["dot"+i].style.pixelTop = yp[i];<BR> document.all["dot"+i].style.pixelLeft = xp[i] + am[i]*Math.sin(dx[i]);<BR> }<BR> else if (ns6up){<BR> document.getElementById("dot"+i).style.top=yp[i];<BR> document.getElementById("dot"+i).style.left=xp[i] + am[i]*Math.sin(dx[i]);<BR> } <BR> }<BR> setTimeout("snowIE_NS6()", 10);<BR> }</P> <P> if (ns4up) {<BR> snowNS();<BR> } else if (ie4up||ns6up) {<BR> snowIE_NS6();<BR> }<BR>// eddig --><BR></SCRIPT> <BR></P> <SCRIPT language=JavaScript1.2> <!-- innen /* Letöltve a ThomasWebMűhely javascript archívumából: http://twm.faxunil.hu/muhely/ */ var snowsrc="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" // a hópehely kép url-je
var no = 10; // a hópelyhek száma a lapon
var ns4up = (document.layers) ? 1 : 0; var ie4up = (document.all) ? 1 : 0; var ns6up = (document.getElementById&&!document.all) ? 1 : 0;
var dx, xp, yp; var am, stx, sty; var i, doc_width = 800, doc_height = 600; // képernyő méretek if (ns4up||ns6up) { doc_width = self.innerWidth; doc_height = self.innerHeight; } else if (ie4up) { doc_width = document.body.clientWidth; doc_height = document.body.clientHeight; }
dx = new Array(); xp = new Array(); yp = new Array(); am = new Array(); stx = new Array(); sty = new Array(); for (i = 0; i < no; ++ i) { dx[i] = 0; xp[i] = Math.random()*(doc_width-50); yp[i] = Math.random()*doc_height; am[i] = Math.random()*20; stx[i] = 0.02 + Math.random()/10; sty[i] = 0.7 + Math.random(); if (ns4up) {
document.write("<layer name=\"dot"+ i +"\" left=\"15\" top=\"15\" visibility=\"show\"><img src='"+snowsrc+"' border=\"0\"></layer>");
} else if (ie4up||ns6up) {
document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><img src='"+snowsrc+"' border=\"0\"></div>");
} } function snowNS() {
for (i = 0; i < no; ++ i) { yp[i] += sty[i]; if (yp[i] > doc_height-50) { xp[i] = Math.random()*(doc_width-am[i]-30); yp[i] = 0; stx[i] = 0.02 + Math.random()/10; sty[i] = 0.7 + Math.random(); doc_width = self.innerWidth; doc_height = self.innerHeight; } dx[i] += stx[i]; document.layers["dot"+i].top = yp[i]; document.layers["dot"+i].left = xp[i] + am[i]*Math.sin(dx[i]); } setTimeout("snowNS()", 10); }
function snowIE_NS6() { // IE and NS6 funkció for (i = 0; i < no; ++ i) { yp[i] += sty[i]; if (yp[i] > doc_height-50) { xp[i] = Math.random()*(doc_width-am[i]-30); yp[i] = 0; stx[i] = 0.02 + Math.random()/10; sty[i] = 0.7 + Math.random(); doc_width = ns6up?window.innerWidth : document.body.clientWidth; doc_height = ns6up?window.innerHeight : document.body.clientHeight; } dx[i] += stx[i]; if (ie4up){ document.all["dot"+i].style.pixelTop = yp[i]; document.all["dot"+i].style.pixelLeft = xp[i] + am[i]*Math.sin(dx[i]); } else if (ns6up){ document.getElementById("dot"+i).style.top=yp[i]; document.getElementById("dot"+i).style.left=xp[i] + am[i]*Math.sin(dx[i]); } } setTimeout("snowIE_NS6()", 10); }
if (ns4up) { snowNS(); } else if (ie4up||ns6up) { snowIE_NS6(); } // eddig --> </SCRIPT>
<DIV id=dot0 style="LEFT: 41px; VISIBILITY: visible; POSITION: absolute; TOP: 93px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot1 style="Z-INDEX: 1; LEFT: 40px; VISIBILITY: visible; POSITION: absolute; TOP: 235px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot2 style="Z-INDEX: 2; LEFT: 422px; VISIBILITY: visible; POSITION: absolute; TOP: 125px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot3 style="Z-INDEX: 3; LEFT: 263px; VISIBILITY: visible; POSITION: absolute; TOP: 237px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot4 style="Z-INDEX: 4; LEFT: 379px; VISIBILITY: visible; POSITION: absolute; TOP: 67px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot5 style="Z-INDEX: 5; LEFT: 304px; VISIBILITY: visible; POSITION: absolute; TOP: 56px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot6 style="Z-INDEX: 6; LEFT: 183px; VISIBILITY: visible; POSITION: absolute; TOP: 153px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot7 style="Z-INDEX: 7; LEFT: 271px; VISIBILITY: visible; POSITION: absolute; TOP: 146px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot8 style="Z-INDEX: 8; LEFT: 208px; VISIBILITY: visible; POSITION: absolute; TOP: 215px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> <DIV id=dot9 style="Z-INDEX: 9; LEFT: 528px; VISIBILITY: visible; POSITION: absolute; TOP: 9px"><IMG src="//gportal.hu/portal/mariannkepei2/image/gallery/coeur.gif" border=0></DIV> |