

/***********************************************
* Fading Scroller- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/

var delay = 2000; //set delay between message change (in miliseconds)
var maxsteps=30; // number of steps to take to change from start color to endcolor
var stepdelay=40; // time in miliseconds of a single step
//**Note: maxsteps*stepdelay will be total time in miliseconds of fading effect
var startcolor= new Array(255,255,255); // start color (red, green, blue)
var endcolor=new Array(0,0,0); // end color (red, green, blue)

var fcontent=new Array();
begintag='<h1>'; //set opening tag, such as font declarations
fcontent[0]="Elyse Unrath";
fcontent[1]="Julie Rimel";
fcontent[2]="Marty Grey";
fcontent[3]="Bek Caruso";
fcontent[4]="Dianne Walsh";
fcontent[5]="Harmony Klohr";
fcontent[6]="Ethel Chinander";
fcontent[7]="Hannah Maximova";
fcontent[8]="Amelia Drinkwater";
fcontent[9]="Lauretta Carra";
fcontent[10]="Viola Robles";
fcontent[11]="Linda LeClair";
fcontent[12]="Bourelle Michel";
fcontent[13]="Michael McClain";
fcontent[14]="Rob Mills";
fcontent[15]="Daniele Olmisani";
fcontent[16]="Kevin W. Smith";
fcontent[17]="Matthew Gilbert";
fcontent[18]="Patty Zatezalo";
fcontent[19]="Constance Mizen";
fcontent[20]="Debbie Stetz";
fcontent[21]="Barbara Freeman";
fcontent[22]="Esta Beerman-Price";
fcontent[23]="Karen Imarisio";
fcontent[24]="Mary-Esther Lee";
fcontent[25]="Lorinda Bollwitt";
fcontent[26]="Erin Nakagawa";
fcontent[27]="Maura West";
fcontent[28]="Frances Deus";
fcontent[29]="Diane Rae";
fcontent[30]="Michael Runyan";
fcontent[31]="Jennifer Drolet";
fcontent[32]="Kristine Larson";
fcontent[33]="James Troutman";
fcontent[34]="Meta Fouts";
fcontent[35]="Gail Knowles";
fcontent[36]="Kari George";
fcontent[37]="Megan McCurry";
fcontent[38]="Mary Beth Cryan";
fcontent[39]="Sandra Garber";
fcontent[40]="Rebecca Kuperberg";
fcontent[41]="Susan E. Amerson";
fcontent[42]="Shante Williams";
fcontent[43]="Judith Barnes Massie";
fcontent[44]="Justin Reich";
fcontent[45]="Sharon Williams";
fcontent[46]="Bonnie J. Smith";
fcontent[47]="Joy Frerichs";
fcontent[48]="Sue Stover";
fcontent[49]="Nancy L. Meacham";
fcontent[50]="Nicco Mele - in memory of Jonas Aarons";
fcontent[51]="Regina Loeffler";
fcontent[52]="Sam Campbell";
fcontent[53]="Patricia Fusco";
fcontent[54]="Carrots Anne";
fcontent[55]="Donna Baumbach";
fcontent[56]="Jessica Savage";
fcontent[57]="Ron Reigner";
fcontent[58]="Jessica Tom";
fcontent[59]="Trudi Olivetti";
fcontent[60]="Jerome Gottschalk";
fcontent[61]="S. Letson";
fcontent[62]="Donna Lee Woolcott";
fcontent[63]="Orapin Muench";
fcontent[64]="Robert Stutts";
fcontent[65]="Alice Raftary";
fcontent[66]="Jerry W. Roth";
fcontent[67]="The Knopick Kids";
fcontent[68]="Nancy Carter";
fcontent[69]="Sherry Parker";
fcontent[70]="Rosalind Fink";
fcontent[71]="Diane M. Fedak";
fcontent[72]="Lindsay Johnson";
fcontent[73]="Bridget Smith";
fcontent[74]="Beth Fein";
fcontent[75]="Terry D'Erchia";
fcontent[76]="Margaret Crawford";
fcontent[77]="Lisa Schaefer";
fcontent[78]="Aiai";
fcontent[79]="Marnie Webster";
fcontent[80]="Susan Melcher";
fcontent[81]="Deborah Kindrick";
fcontent[82]="K. & S. Marantz";
fcontent[83]="Robert Orr";
fcontent[84]="Alison Fornes";
fcontent[85]="Amy Whitacre";
fcontent[86]="Bernadette Weigler";
fcontent[87]="Brian Hulse";
fcontent[88]="Amee Pollack";
fcontent[89]="Alberto Castanini";
fcontent[90]="Jess Tice";
fcontent[91]="Peter Moulinos";
fcontent[92]="Michelle Davila Majoros";
fcontent[93]="Sam Ita";
fcontent[94]="Elliott Gerber";
fcontent[95]="Hal Barrier";
fcontent[96]="Nancy Whiteley";
fcontent[97]="Grace Li";
fcontent[98]="Barbara Herzinger";
fcontent[99]="Stephanie Lorraine Nickolan-Barron";
fcontent[100]="Richard Hedke";
fcontent[101]="Marsha Baird";
fcontent[102]="Linda Thurber";
fcontent[103]="Marian Allan";
fcontent[104]="Adriana S. Thorpe";
fcontent[105]="C.S. Budny";
fcontent[106]="Nick Green";
fcontent[107]="Wendy Sabuda";
fcontent[108]="Easter Chapman";
fcontent[109]="Rebecca Emberley";
fcontent[110]="Michelle Brejnak";
fcontent[111]="Andrea Partiti";
fcontent[112]="Jill Purdy";
fcontent[113]="Mim Gottschalk";
fcontent[114]="Colleen A. Moore";
fcontent[115]="Manida Sry";
fcontent[116]="Julie Cook";
fcontent[117]="Bill Gosling";
fcontent[118]="Cat Domiano";
fcontent[119]="Helaine Witt";
fcontent[120]="Rebecca Mack";
fcontent[121]="Patricia M. Ellis";
fcontent[122]="Cynthia Parfitt";
fcontent[123]="Rae Reyes";
fcontent[124]="Joan Goliak";
fcontent[125]="Dina Sabuda";
fcontent[126]="Donna Harder";
fcontent[127]="Cyrus Boquin";
fcontent[128]="Judi Corvinelli";
fcontent[129]="Rosalyn Berman";
fcontent[130]="Anna and Tess Knoebel";
fcontent[131]="Michael J. Droller";
fcontent[132]="L.P. Robbins";
fcontent[133]="Becky McDonald";
fcontent[134]="Ann Richardson";
fcontent[135]="John Besnard";
fcontent[136]="Jeffrey Stackhouse";
fcontent[137]="Debbie Gerlock";
fcontent[138]="Andrew Kauffman";
fcontent[139]="Cheryl Ma";
fcontent[140]="Fiora Dunn";
fcontent[141]="Frank Di Memmo";
fcontent[142]="Carol A. Johnson";
fcontent[143]="Nancy Loong";
fcontent[144]="Sue McCleaf Nespeca";
fcontent[145]="Suzy Sotelo";
fcontent[146]="Jennifer Liu";
fcontent[147]="Maria Segnalini";
fcontent[148]="Joan Bucher Reeve";
fcontent[149]="Bill Waggoner";
fcontent[150]="K.A. Okagaki";
fcontent[151]="Petrina Klitgord Case";
fcontent[152]="Amy Dell";
fcontent[153]="Joan E. Smith";
fcontent[154]="Janet Simeone";
fcontent[155]="Bruce Foster";
fcontent[156]="Angie Baumgartner";
fcontent[157]="Jennifer Smith Palmer";
fcontent[158]="Karyn K. Wagner";
fcontent[159]="Elliot Kreloff";
fcontent[160]="Lauri Fortino";
fcontent[161]="Beth Hedges";
fcontent[162]="Michael Caputo";
fcontent[163]="Sujata Shahane";
fcontent[164]="Sue McCleaf Nespeca";
fcontent[165]="Mario Rups";
fcontent[166]="Ken Geist";
fcontent[167]="C. William & Linda Mattoon";
fcontent[168]="Deborah & Spencer Ward, M.D.";
fcontent[169]="Irene Brown";
fcontent[170]="Connie L. Swanson";
fcontent[171]="Nancy L. Davies";
fcontent[172]="Idee Schoenheimer";
fcontent[173]="Larry Seidman";
fcontent[174]="Steve Erickson";
fcontent[175]="Nicole Benjamin-Ma";
fcontent[176]="Cyndi Giorgis";
fcontent[177]="Barbara Emberley";
fcontent[178]="Mary Picucci";
fcontent[179]="Debbie Lillick";
fcontent[180]="Dorothy Berman";
fcontent[181]="Debra Linkert";
fcontent[182]="Kaye Price-Hawkins";
fcontent[183]="David Mordini";
fcontent[184]="Frank Hieronymus";
fcontent[185]="Peter Glassman";
fcontent[186]="Rich Hjulstrom";
fcontent[187]="Margaret Beach";
fcontent[188]="David Durham";
fcontent[189]="Sweta Jayaram";
fcontent[190]="Mark Talisman";
fcontent[191]="Steven Landau";
fcontent[192]="Sherry Parker";
fcontent[193]="Andrew Yerre";
fcontent[194]="Richard Massie";
fcontent[195]="Todd Baumgartner";
fcontent[196]="Andrew Wilson";
fcontent[197]="Patricia Covington";
fcontent[198]="Ricki Schweizer";
fcontent[199]="Jennie Dunham";
fcontent[200]="Concha Munoz de Valladolid";
fcontent[201]="Mr. & Mrs Michael L. Deles, Jr.";
fcontent[202]="Linda Hawkins";
fcontent[203]="Christy Keyes";
fcontent[204]="Fran Jutzi";
fcontent[205]="Lincoln Mennuti";
fcontent[206]="Janet";
fcontent[207]="Kaikudo";
fcontent[208]="Jackie";
fcontent[209]="Ritu Sudharshan";
fcontent[210]="Elsa";
closetag='</h1>';

var fwidth='400px'; //set scroller width
var fheight='50px'; //set scroller height

var fadelinks=1;  //should links inside scroller content also fade like text? 0 for no, 1 for yes.

///No need to edit below this line/////////////////


var ie4=document.all&&!document.getElementById;
var DOM2=document.getElementById;
var faderdelay=0;
var index=0;


/*Rafael Raposo edited function*/
//function to change content
function changecontent(){
  if (index>=fcontent.length)
    index=0
  if (DOM2){
    document.getElementById("fscroller").style.color="rgb("+startcolor[0]+", "+startcolor[1]+", "+startcolor[2]+")"
    document.getElementById("fscroller").innerHTML=begintag+fcontent[Math.floor(Math.random()*fcontent.length)]+closetag
    if (fadelinks)
      linkcolorchange(1);
    colorfade(1, 15);
  }
  else if (ie4)
    document.all.fscroller.innerHTML=begintag+fcontent[index]+closetag;
  index++
}

// colorfade() partially by Marcio Galli for Netscape Communications.  ////////////
// Modified by Dynamicdrive.com

function linkcolorchange(step){
  var obj=document.getElementById("fscroller").getElementsByTagName("A");
  if (obj.length>0){
    for (i=0;i<obj.length;i++)
      obj[i].style.color=getstepcolor(step);
  }
}

/*Rafael Raposo edited function*/
var fadecounter;
function colorfade(step) {
  if(step<=maxsteps) {	
    document.getElementById("fscroller").style.color=getstepcolor(step);
    if (fadelinks)
      linkcolorchange(step);
    step++;
    fadecounter=setTimeout("colorfade("+step+")",stepdelay);
  }else{
    clearTimeout(fadecounter);
    document.getElementById("fscroller").style.color="rgb("+endcolor[0]+", "+endcolor[1]+", "+endcolor[2]+")";
    setTimeout("changecontent()", delay);
	
  }   
}

/*Rafael Raposo's new function*/
function getstepcolor(step) {
  var diff
  var newcolor=new Array(3);
  for(var i=0;i<3;i++) {
    diff = (startcolor[i]-endcolor[i]);
    if(diff > 0) {
      newcolor[i] = startcolor[i]-(Math.round((diff/maxsteps))*step);
    } else {
      newcolor[i] = startcolor[i]+(Math.round((Math.abs(diff)/maxsteps))*step);
    }
  }
  return ("rgb(" + newcolor[0] + ", " + newcolor[1] + ", " + newcolor[2] + ")");
}

if (ie4||DOM2)
  document.write('<div id="fscroller" style="width:'+fwidth+';height:'+fheight+'"></div>');

if (window.addEventListener)
window.addEventListener("load", changecontent, false)
else if (window.attachEvent)
window.attachEvent("onload", changecontent)
else if (document.getElementById)
window.onload=changecontent


