setinterval - Setting timer for a javascript randomizer -


the randomizer works, looking way loop using setinterval can continuously run in own div on website.

<script language="javascript"> setinterval(quotes(), 3000); function quotes(i) {     var r_text = new array();     r_text[0] = "all leaves brown";     r_text[1] = "and sky grey";     r_text[2] = "i've been walk";     r_text[3] = "on winter's day";     r_text[4] = "i'd safe , warm";     r_text[5] = "if in l.a.";     r_text[6] = "california dreaming, on such winter's day";     var = math.floor(7 * math.random())     document.write(r_text[i]); } </script> 

change setinterval(quotes(), 3000); setinterval(quotes, 3000);


Popular posts from this blog