function flipQuote() {
  Effect.Fade(quoteList[curIndex], {afterFinish: showNextQuote});
}
function showNextQuote() {
  curIndex = (curIndex + 1) % quoteList.length;
  Effect.Appear(quoteList[curIndex], {afterFinish: function() {setTimeout(flipQuote, 8000);}});
};

var quoteList = $$('div.quote');
var curIndex = quoteList.length-1;
flipQuote();

