// JavaScript Document

var num;

var backgroundColors;

function setUp()

{
	num=0;
	backgroundColors = new Array(
	"#FFFF00",
	"#33FFFF",
	"#FF99CC",
	"#33FF00");
}


	setInterval ("doSomething()", 1000);
	function doSomething()
{
	num ++;
	if (num == 4)
		{
			num = 0;
		}

	var element = document.getElementById("wholePage"); 
//  Target your DIV
var myAnim = new YAHOO.util.ColorAnim(element, {backgroundColor: { to: backgroundColors[num] } }); 
//  Use this YUI code, but note how I insert the call to our array
	myAnim.animate();
//  This is a YUI call to their animate function

}

	function myScroll()
{
	
    var attributes = { 
        scroll: { to: [0, 200] } 
    }; 
    //  YUI code to set the attributes of the scroll	
	var i = document.getElementById("articleText");
    //  Our code to target the element to scroll	
    var animScroll = new YAHOO.util.Scroll(i, attributes); 
    //  YUI code to scroll our target element	
	animScroll.animate(); 
    //  YUI code to begin the scroll		
}

	function doResize()
{
  var attributes = { 
	   width: { from: 140, to: 400 }, 
	   height: { from: 40, to: 70 }
	}; 
    //  YUI code for the changes in height and width	
	var j = document.getElementById("resizeMe");
    //  Our code to target our DIV	
	var myAnimResize = new YAHOO.util.Anim(j, attributes); 
    //  YUI code to connect our DIV with the change attributes		
	myAnimResize.animate(); 
    //  YUI code to do the change in size		

	var k = document.getElementById("yucky");
	//  Our code to target our paragraph	
	k.innerHTML = 
    "<span style='color:blue;padding:50px;font-size:xx-large'>Really, really yucky!</span>";
    //  Our code to set the inner HTML of the paragraph	
}

	