-
December 4th, 2002, 09:43 AM
#1
Senior Member
Useful Javscript
hello everyone
Falling Snow
The season is here - and the big day is closing in. It's time to put your website in the mood, too!
This script is very small - and requires absolutely no images, thus it has a very quick load time. All of the parameters can be changed at the top of the javascript.
( got this in mah email )
\"I have a 386 Pentium.\"
-
December 4th, 2002, 10:16 AM
#2
I'm sorry what script ??
here you have one with images http://www.altan.hr/snow/
this rain , drop can be transfirmed into a snow * flake http://javascript.internet.com/bgeffects/rain.html
this is just the one you and I were talking about, but then in dutch http://www.javascript.nl/scripts.php...ript&scr_id=60
ASCII stupid question, get a stupid ANSI.
When in Russia, pet a PETSCII.
Get your ass over to SLAYRadio the best station for C64 Remixes !
-
December 5th, 2002, 12:26 PM
#3
Senior Member
sorry, file didnt attach
hello again people
forgive me for not checking the file that didnt attach
i didnt get time to see if my fellow friend meant the same script above, but i have this file here so im simply attaching it.
thanks
\"I have a 386 Pentium.\"
-
December 5th, 2002, 12:55 PM
#4
Banned
thanks invader, that was help
-
December 11th, 2002, 09:01 AM
#5
Senior Member
\"I have a 386 Pentium.\"
-
December 11th, 2002, 10:08 AM
#6
Do you want a nice script for snow this is greet
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
var no = 50;
var speed = 1;
var ns4up = (document.layers) ? 1 : 0;
var ie4up = (document.all) ? 1 : 0;
var s, x, y, sn, cs;
var a, r, cx, cy;
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;
}
x = new Array();
y = new Array();
r = new Array();
cx = new Array();
cy = new Array();
s = 8;
for (i = 0; i < no; ++ i) {
initRain();
if (ns4up) {
if (i == 0) {
document.write("<layer name=\"dot"+ i +"\" left=\"1\" ");
document.write("top=\"1\" visibility=\"show\"><font color=\"blue\">");
document.write(",</font></layer>");
}
else {
document.write("<layer name=\"dot"+ i +"\" left=\"1\" ");
document.write("top=\"1\" visibility=\"show\"><font color=\"blue\">");
document.write(",</font></layer>");
}
}
else
if (ie4up) {
if (i == 0) {
document.write("<div id=\"dot"+ i +"\" style=\"POSITION: ");
document.write("absolute; Z-INDEX: "+ i +"; VISIBILITY: ");
document.write("visible; TOP: 15px; LEFT: 15px;\"><font color=\"blue\">");
document.write(",</font></div>");
}
else {
document.write("<div id=\"dot"+ i +"\" style=\"POSITION: ");
document.write("absolute; Z-INDEX: "+ i +"; VISIBILITY: ");
document.write("visible; TOP: 15px; LEFT: 15px;\"><font color=\"blue\">");
document.write(",</font></div>");
}
}
}
function initRain() {
a = 6;
r[i] = 1;
sn = Math.sin(a);
cs = Math.cos(a);
cx[i] = Math.random() * doc_width + 1;
cy[i] = Math.random() * doc_height + 1;
x[i] = r[i] * sn + cx[i];
y[i] = cy[i];
}
function makeRain() {
r[i] = 1;
cx[i] = Math.random() * doc_width + 1;
cy[i] = 1;
x[i] = r[i] * sn + cx[i];
y[i] = r[i] * cs + cy[i];
}
function updateRain() {
r[i] += s;
x[i] = r[i] * sn + cx[i];
y[i] = r[i] * cs + cy[i];
}
function raindropNS() {
for (i = 0; i < no; ++ i) {
updateRain();
if ((x[i] <= 1) || (x[i] >= (doc_width - 20)) || (y[i] >= (doc_height - 20))) {
makeRain();
doc_width = self.innerWidth;
doc_height = self.innerHeight;
}
document.layers["dot"+i].top = y[i];
document.layers["dot"+i].left = x[i];
}
setTimeout("raindropNS()", speed);
}
function raindropIE() {
for (i = 0; i < no; ++ i) {
updateRain();
if ((x[i] <= 1) || (x[i] >= (doc_width - 20)) || (y[i] >= (doc_height - 20))) {
makeRain();
doc_width = document.body.clientWidth;
doc_height = document.body.clientHeight;
}
document.all["dot"+i].style.pixelTop = y[i];
document.all["dot"+i].style.pixelLeft = x[i];
}
setTimeout("raindropIE()", speed);
}
if (ns4up) {
raindropNS();
}
else
if (ie4up) {
raindropIE();
}
// End -->
</script>
More to come http://www.hackerswarrior.fr.st opening February
-
December 11th, 2002, 10:55 AM
#7
Originally posted here by HackersWarrioR
Do you want a nice script for snow this is greet
If you want to contribute, don't do it by copy-pasting and leaving it impled as if it was your own.
And if you looked you would have noticed that that code is for RAIN, not SNOW... Tsk tsk tsk.
[HvC]Terr: L33T Technical Proficiency
-
December 30th, 2002, 12:10 PM
#8
Senior Member
The script that changes images everyday , depending upon the day .
It is useful in places, where you need to greet people according to their own timezones :
<script language="javascript1.1"> today = new Date(); day = today.getDay(); arday = new Array("Sunday.jpg", "Monday.jpg", "Tuesday.jpg", "Wednesday.jpg", "Thursday.jpg", "Friday.jpg", "Saturday.jpg"); document.write("[img]" + arday[day] + "[/img]"); </script>
( it was a short script, so i thought a separate file wasnt needed )
\"I have a 386 Pentium.\"
-
December 30th, 2002, 07:14 PM
#9
Senior Member
Hey Invader, I tried setting this as a backround for a web page and it's not working. Do you have any ideas or thoughts of why this is not working. It seems that I have tried everything!
[pong][blur]Victory to Success[/blur][/pong]is only half won through the[pong][blur]Habit of Hard Work...[/blur][/pong]
-Jagfire19
-
December 31st, 2002, 11:08 AM
#10
Senior Member
How can it be not working ? did you place it in the body tag or your HTML ?
try both ways,in and out the body tag.
\"I have a 386 Pentium.\"
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|