var zentry = new Array();

zentry[1] = "Haltingly beautiful and innovative,<br>we think of Diana Vincent's work<br>not as jewelry,<br>but as highly functional pieces of art....<p>&mdash;Maria</p>";

zentry[2] = "There isn't a day that goes by that I am not wearing a piece of Diana Vincent jewelry.<br>It's unique and perfect for every occasion.<p>&mdash;Diane</p>";

zentry[3] = "One does not have to go to Fifth Avenue to find the most beautiful and exciting jewelry.<br>It's all right here at Diana Vincent.<p>&mdash;Vivian</p>";

zentry[4] = "We looked everywhere for our engagement and wedding rings &mdash; Center City, New Hope, New York. We weren't having any luck finding designs that were unique and us... until we stopped into Diana Vincent.<p>&mdash;Brian</p>";

zentry[5] = "Your designs are simple,<br>exquisite and most important: unique.<p>&mdash;Walter</p>";

zentry[6] = "Very unique ....don't see everywhere.<p>&mdash;Betty</p>";

zentry[7] = "Designs are great.<br>They are original and beautiful...<p>&mdash;Sue</p>";

zentry[8] = "Owning a piece of DV jewelry<br>is owning a work of art,<br>with the added benefit<br>of being able to wear it.<p>&mdash;Katherine</p>";

delay = 15000;		// 1000 = 1 second





// * * * * * PLEASE DO NOT EDIT BEYOND THIS POINT * * * * *

hexinput = 191;  // Initial color value, was 255.
var inc = -1; //increment variable
fadeSpeed = 100; //higher number is slower, lower number is faster
var now = new Date()
itemElements = zentry.length-1;
zLoop = 0;	// 0 = no, 1 = yes

function fadingtext(){
	if(hexinput>0) {	
		hexinput-=11; // increase color value
		document.getElementById("fader").style.color="rgb("+hexinput+","+hexinput+","+hexinput+")"; // Set color value.
		setTimeout("fadingtext()",fadeSpeed);	
	}
	else {
		//reset hex value
		hexinput = 191;
		}
}



function changetext() {
	if (!document.getElementById) return

	rndPick = rand(itemElements);
	document.getElementById("fader").innerHTML= zentry[rndPick];

	fadingtext();

	if (zLoop == 1) {
			prevVal = rndPick;

			do {
			rndPick = rand(itemElements);
			} while (rndPick == prevVal);

			setTimeout("changetext()",delay);
		}
	else
		{
			return
		}
}


function rand(x)
{
    var seed = now.getTime() % 0xffffffff
    seed = (0x015a4e35 * seed) % 0x7fffffff;
    zResult = (seed >> 16) % x;
// if result is 0, use max number
    if (zResult == 0) {zResult = x;}
    return (zResult); 
}

window.onload=changetext;
