Jump to content

noname

Members
  • Posts

    4
  • Joined

  • Last visited

Contact Methods

  • Website URL
    http://
  • ICQ
    0
  • Yahoo
    barney22211

Profile Information

  • Interests
    chocolate, ice-cream, computer, music

noname's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. I want to keep changing a text's color, but it display many text with another colors
  2. <HTML><HEAD><TITLE> Text </TITLE><script type="text/javascript">var colors=new Array();colors[0]="blue";colors[1]="green";colors[2]="red";colors[3]="grey";colors[4]="orange";colors[5]="aqua";colors[6]="brown";colors[7]="black";colors[8]="purple";colors[9]="chocolate";colors[10]="magenta";colors[11]="violet";colors[12]="indigo";colors[13]="sienna";colors[14]="yellow";var i=0;var t;function writemess(){ if(i==colors.length) return; document.write(str.fontcolor(colors[i++])); t=setTimeout('writemess()',200); //writemess(); }</script></HEAD><BODY onload="writemess()"> </BODY></HTML>
  3. hi, I've just begun to learn java script , i have a exercises, its description : "You should keep changing a text's color". I have a array to containt colors, but when i use setTimeout() and document.write() to display the text, have a error: Object expected. Can you help me to slove this proplem ? thanks
×
×
  • Create New...