// Randomly selects a praise quotation

var NUM_PICS = 6;
var NUM_QUOTES = 9;

var quoteList = new Array(NUM_QUOTES);
quoteList[0] = "<p class=\"quote\">&ldquo;Name me a Burgundy cellar where someone could walk through and taste all the cuv&eacute;es and find such extraordinary levels of quality.&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine&nbsp;Advocate</p><p class=\"cite\">December, 2003</p>"
quoteList[1] = "<p class=\"quote\">&ldquo;&hellip;Steve Kistler and his partner, Mark Bixler, are at the top of their game, making world-class Chardonnays of remarkable consistency.&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine&nbsp;Advocate</p><p class=\"cite\">December, 2003</p>"
quoteList[2] = "<p class=\"quote\">&ldquo;I am more and more convinced that Kistler&hellip;is producing historic Chardonnays and Pinot Noirs that may one day be considered to have rewritten the definition of greatness for these varietals.&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine&nbsp;Advocate</p><p class=\"cite\">December, 2000</p>"
quoteList[3] = "<p class=\"quote\">&ldquo;Given the breadth of Chardonnays and Pinot Noirs produced by Steve Kistler, he is the undeniable master of these two varietals in California.&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine Advocate</p><p class=\"cite\">December, 2000</p>"
quoteList[4] = "<p class=\"quote\">&ldquo;Steve Kistler and Mark Bixler are justifiably proud of what they have achieved with Chardonnay, but what really turns them on is their accomplishments with Pinot Noir, which may be the greatest Pinot Noirs being made in the New World.&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine Advocate</p><p class=\"cite\">December, 2000</p>"
quoteList[5] = "<p class=\"quote\">&ldquo;If the Kistler Winery could be magically transported to the middle of Burgundy&rsquo;s C&ocirc;te d&rsquo;Or, it would quickly gain a reputation as glorious as any producer of Burgundy grand crus.&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine Advocate</p><p class=\"cite\">December, 1999</p>"
quoteList[6] = "<p class=\"quote\">&ldquo;In recent years, Kistler has turned in a virtually flawless performance. This is acknowledged, indeed embraced, by its legion of fans&hellip;At the moment, it is probably the source of more Chardonnays of the highest caliber than any other California winery.&rdquo;</p><p class=\"cite who\">&mdash;Matt Kramer</p><p class=\"cite where\">Matt Kramer's New&nbsp;California&nbsp;Wine</p><p class=\"cite\"> September, 2004</p>"
quoteList[7] = "<p class=\"quote\">&ldquo;Probably Kistler&rsquo;s most famous Chardonnay is its Dutton Ranch, which put that brand name&hellip;in lights. Everyone&rsquo;s Dutton Ranch Chardonnay is different, and you can bet that no one&rsquo;s is better than Kistler&rsquo;s in its taut yet honeyed scent and taste.&rdquo;</p><p class=\"cite who\">&mdash;Matt Kramer</p><p class=\"cite where\">Matt Kramer's New&nbsp;California&nbsp;Wine</p><p class=\"cite\">September, 2004</p>"
quoteList[8] = "<p class=\"quote\">&ldquo;With so many great vintages recently, the 2001s were stunning, the 2002s sumptuous, and now the 2003s, which are big, generous, ripe wines&hellip;&rdquo;</p><p class=\"cite who\">&mdash;Robert Parker</p><p class=\"cite where\">The Wine Advocate</p><p class=\"cite\">December, 2004</p>"


function rand(limit) // returns random integer from 0 to (limit - 1)
{
	return Math.round(Math.random()*(limit-1))
}

function insertQuote() // Inserts a random quote from quoteList[]
{
	document.write(quoteList[rand(NUM_QUOTES)]);
}

function randomPic() // Inserts a random picture
{
	document.write("<img name=\"pic\" id=\"pic\" src=\"/assets/cycle/cycle_pic" + (rand(NUM_PICS)+1) + ".jpg\" align=\"left\" border=\"0\" onclick=\"history.go()\">");
}




//////////////////////////////////////////////////////////////////////////////////////////
// The following functions were automatically inserted into the template by Dreamweaver.
// I took them out to save space
//////////////////////////////////////////////////////////////////////////////////////////

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_nbGroup(event, grpName) { //v6.0
  var i,img,nbArr,args=MM_nbGroup.arguments;
  if (event == "init" && args.length > 2) {
    if ((img = MM_findObj(args[2])) != null && !img.MM_init) {
      img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src;
      if ((nbArr = document[grpName]) == null) nbArr = document[grpName] = new Array();
      nbArr[nbArr.length] = img;
      for (i=4; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
        if (!img.MM_up) img.MM_up = img.src;
        img.src = img.MM_dn = args[i+1];
        nbArr[nbArr.length] = img;
    } }
  } else if (event == "over") {
    document.MM_nbOver = nbArr = new Array();
    for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i])) != null) {
      if (!img.MM_up) img.MM_up = img.src;
      img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])? args[i+1] : img.MM_up);
      nbArr[nbArr.length] = img;
    }
  } else if (event == "out" ) {
    for (i=0; i < document.MM_nbOver.length; i++) {
      img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn : img.MM_up; }
  } else if (event == "down") {
    nbArr = document[grpName];
    if (nbArr)
      for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src = img.MM_up; img.MM_dn = 0; }
    document[grpName] = nbArr = new Array();
    for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
      if (!img.MM_up) img.MM_up = img.src;
      img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up;
      nbArr[nbArr.length] = img;
  } }
}
