Je┐eli wstawimy ten skrypt, to na naszej stronie bΩdzie wy╢wietlana jedna ze zdefiniowych przez nas porad dnia. Dany skrypt nale┐y wstawiµ w sekcji body.


<SCRIPT LANGUAGE="JavaScript">

// poni┐ej trzeba wstawiµ liczbΩ autor≤w i porad (w nawiasie)
quotes = new Array(6);
authors = new Array(6);

// tutaj nale┐y wstawiµ nasze porady
quotes[0] = "Porada 1";
authors[0] = "Autor 1";
quotes[1] = "Porada 2";
authors[1] = "Autor 2";
quotes[2] = "Porada 3";
authors[2] = "Autor 3";
quotes[3] = "Porada 4";
authors[3] = "Autor 4";
quotes[4] = "Porada 5";
authors[4] = "Autor 5";
quotes[5] = "Porada 6";
authors[5] = "Autor 6";

// losowanie liczby
index = Math.floor(Math.random() * quotes.length);

// wyswietlenie porady dnia
document.write("<DL>\n");
document.write("<DT>" + "\"" + quotes[index] + "\"\n");
document.write("<DD>" + "-- " + authors[index] + "\n");
document.write("</DL>\n");

//done
</SCRIPT>

Pawe│ 'profesor' Nasi│owski 
internet@at.bjn.pl
 
http://pawel.plywanie.pl/