Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.

Sneg na mom sajtu... Pisan u CSS-u...

[es] :: Web dizajn i CSS :: Sneg na mom sajtu... Pisan u CSS-u...

[ Pregleda: 4647 | Odgovora: 4 ] > FB > Twit

Postavi temu Odgovori

Autor

Pretraga teme: Traži
Markiranje Štampanje RSS

milos036

Član broj: 87169
Poruke: 209
212.200.115.*



Profil

icon Sneg na mom sajtu... Pisan u CSS-u...04.11.2006. u 19:46 - pre 211 meseci
Kako izvesti da pahuljice padaju na mom sajtu?
 
Odgovor na temu

WawaHOO!
Karaburma

Član broj: 86823
Poruke: 602
*.adsl.sezampro.yu.

Sajt: www.infobuk.com


Profil

icon Re: Sneg na mom sajtu... Pisan u CSS-u...04.11.2006. u 20:54 - pre 211 meseci
Stavi ga u dvoriste

Code:
<script language="JavaScript1.2">
var snowsrc="images/nekaslika.gif" ;
var no = 10;
var ns4up = (document.layers) ? 1 : 0;
var ie4up = (document.all) ? 1 : 0;
var dx, xp, yp;
var am, stx, sty;
var i, doc_width = 800, doc_height = 600;
if (ns4up) {
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) {
if (i == 0) {
document.write("<layer name=\"dot"+ i +"\" left=\"15\" top=\"15\" visibility=\"show\"><img src='"+snowsrc+"' border=\"0\"></layer>");
} else {
document.write("<layer name=\"dot"+ i +"\" left=\"15\" top=\"15\" visibility=\"show\"><img src='"+snowsrc+"' border=\"0\"></layer>");
}
} else if (ie4up) {
if (i == 0) {
document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><img src='"+snowsrc+"' border=\"0\"></div>");
} else {
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() {
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 = document.body.clientWidth;
doc_height = document.body.clientHeight;
}
dx[i] += stx[i];
document.all["dot"+i].style.pixelTop = yp[i];
document.all["dot"+i].style.pixelLeft = xp[i] + am[i]*Math.sin(dx[i]);
}
setTimeout("snowIE()", 20);
}
if (ns4up) {
snowNS();
} else if (ie4up) {
snowIE();
}
</script>

 
Odgovor na temu

Mitrović Srđan
bloodzero
Freelance
Majur //: Šabac

Član broj: 10261
Poruke: 2800
62.108.116.*

Sajt: freeshell-reviews.com


+4 Profil

icon Re: Sneg na mom sajtu... Pisan u CSS-u...04.11.2006. u 21:10 - pre 211 meseci
Citat:

Stavi ga u dvoriste


GENIJALNO!!!
Jeste offtopic ali ovo je prejako :)
Tony Melendez:
http://video.google.com/videoplay?docid=-
3819862628517136815&q=tony+melendez

NIKADA NE UZIMATI HOSTING NA GO DADDY!


 
Odgovor na temu

milos036

Član broj: 87169
Poruke: 209
212.200.115.*



Profil

icon Re: Sneg na mom sajtu... Pisan u CSS-u...10.11.2006. u 13:01 - pre 211 meseci
Ovo je ok ali kako to da radi i u Firefox-u...
 
Odgovor na temu

dragancesu
subotica

Član broj: 38340
Poruke: 2189
*.eunet.yu.



+73 Profil

icon Re: Sneg na mom sajtu... Pisan u CSS-u...10.11.2006. u 16:15 - pre 211 meseci
Pogledaj www.maxxblade.co.uk
Pomozite Micro$oftu u borbi protiv piraterije, poklonite prijatelju Linux
 
Odgovor na temu

[es] :: Web dizajn i CSS :: Sneg na mom sajtu... Pisan u CSS-u...

[ Pregleda: 4647 | Odgovora: 4 ] > FB > Twit

Postavi temu Odgovori

Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.