var DenImg = new Image();
DenImg.src = 'images/testimonials/miami.gif';
var AlabamaImg = new Image();
AlabamaImg.src = 'images/testimonials/alabama.gif';

function makeNews(c,l,s, f,i){
	this.copy = c;
	this.link = l;
	this.sign = s;
	this.follow = f;
	this.img = i;
	this.write = writeNews;
}

function writeNews(){
	var str = '';
	str += '<ul style="padding:10px 0px 0px 0px; margin:0px" class="testimonialcontent"><p style="padding-top:0px;margin-top:5px;padding-right:5px;">'+ this.copy ;
	str += '<img border="0" align="left" src="' + this.img.src + '">';
	str += '<br/>' + this.sign + '<br/>';
        str +=  '<small><a rel="nofollow" href="' + this.link + '" target="_blank">' + this.follow + '</a></small></p>  </ul>  ';
	return str;
}

var newsArray = new Array();
newsArray[0] = new makeNews("&quot;Finding good, dependable, and talented strategic partners can be challenging at times. Finding those who go above the bar in providing excellent customer service is a rare find, but a necessity in today&rsquo;s economic market. USADATA filled these needs for us in our recent direct mail campaign perfectly.&quot;<br/>", 'http://www.miami.muohio.edu', '<small>Kimberly Snow Logsdon<br>Miami University</small>' , 'www.miami.muohio.edu',DenImg).write();

newsArray[1] = new makeNews("&quot;We facilitate distance degrees for almost seventy degree programs. Having USADATA around to help us find mailing lists as we seek out our best prospective students is so helpful. Their quick response time makes it much easier to market our programs for individual colleges that we serve here on our campus.&quot;<br/>",'http://www.ccs.ua.edu', '<small>Johnnie Blackburn - College of Continuing Studies<br/> The University of Alabama</small>', 'www.ccs.ua.edu',AlabamaImg).write();



var nIndex = 0;
var timerID = null;
function rotateNews(){
	var len = newsArray.length;
	if(nIndex >= len)
		nIndex = 0;
	document.getElementById('stories').innerHTML = newsArray[nIndex];
	nIndex++;
	timerID = setTimeout('rotateNews()',10000);
}
function pauseNews() {
	if (timerID != null) {
		clearTimeout(timerID);
		timerID = null;
	}
}

function playNews() {
	if (timerID == null) {
		timerID = setTimeout('rotateNews()', 10000);
	}
}

