/*********************/var featurePath = 'images/feature/';var featureSets = 4;var promos = 0;/*********************/show((0), 'hidden'); // Hide feature images to avoid flickershow((1), 'none'); // Hide default promo to avoid flickerfunction show(rule, state) {	var theRules = new Array();	if (document.styleSheets[0].cssRules) {		theRules = document.styleSheets[0].cssRules;	}	else if (document.styleSheets[0].rules) {		theRules = document.styleSheets[0].rules;	}	if(state == "visible" || state == "hidden") {		theRules[rule].style.visibility = state;	}	else {		theRules[rule].style.display = state;	}}function randomInt(minimum, maximum) {;	var randomInt = Math.floor(Math.random() * (maximum - minimum) + minimum);	return randomInt;}function features() {	var minimum = 1;	var maximum = featureSets + 1;	var randomNumber = randomInt(minimum, maximum);	for(var count=1; count<=4; count++) {		var imageID = 'feature_' + count;		var source =  featurePath + 'week' + randomNumber + '_' + count + '.jpg'; // filename format: "week[x]_[1-4].jpg"		document.getElementById(imageID).src = source;	}	show(0, 'visible');}
function promo() {	var promo;	var minimum = 0;	var maximum = promos + 1;	var randomNumber = randomInt(minimum, maximum);	switch(randomNumber) {		case 0:	// If featurePackage is 0, the default is left on			promo = '';			show(1, 'block');		break;		case 1:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/uihealthaccess\/index.html"><img src="images\/promo\/access.jpg" width="175" \/><span>UI Health Access<br>Your 24\/7 resource for health and service information<\/span><\/a>'		break;		case 2:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/volunteerprogram\/cradleandall.html"><img src="images\/promo\/cradle.jpg" width="175" \/><span>Cradle and All<br>For the new baby in your life.<\/span><\/a>'		break;		case 3:		promo = '<a href="http:\/\/www.healthcare.uiowa.edu\/Programs\/Volunteerservices\/emailpatient.asp"><img src="images\/promo\/email.jpg" width="175" \/><span>e-mail a Patient<\/span><\/a>'		break;		case 4:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/uifamilycare\/index.html"><img src="images\/promo\/family.jpg" width="175" \/><span>My ideal doctor provides the best of both worlds. <br>UI Family Care<\/span><\/a>'		break;		case 5:		promo = '<a href="http:\/\/www.uihealthcare.com\/infofor\/jobs\/index.html"><img src="images\/promo\/job.jpg" width="175" \/><span>Interested in working here?<\/span><\/a>'		break;		case 6:		promo = '<a href="http:\/\/www.uihealthcare.com\/kxic\/index.html"><img src="images\/promo\/kxic.jpg" width="175" \/><span>University of Iowa Health Care Today (KXIC)<\/span><\/a>'		break;		case 7:		promo = '<a href="http:\/\/www.uihealthcare.com\/infofor\/patients\/rightsresponsibilities.html"><img src="images\/promo\/patientrights.jpg" width="175" \/><span>Patient rights and responsibilities<\/span><\/a>'		break;		case 8:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/volunteerprogram\/becoming.html"><img src="images\/promo\/volunteers.jpg" width="175" \/><span>Interested in volunteering?<\/span><\/a>'		break;		case 9:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/volunteerprogram\/giftshop\/index.html"><img src="images\/promo\/wildrose.jpg" width="175" \/><span>Need a gift? Wild Rose Gifts<\/span><\/a>'		break;		case 10:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/uiquickcare\/index.html"><img src="images\/promo\/quickcare.jpg" width="175" \/><span>UI QuickCare: Convenient. Affordable.<br>No appointment necessary.<\/span><\/a>'		break;		case 11:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/med\/obgyn\/clinics\/nursemidwife\/index.html"><img src="images\/promo\/midwife.jpg" width="175" \/><span>Nurse-Midwifery: A natural choice.<br>Now available at UI Family Care in North Liberty.<\/span><\/a>'		break;				case 12:		promo = '<a href="http:\/\/www.uihealthcare.com\/depts\/uiheartcare\/hra.html"><img src="images\/promo\/heartbeat.jpg" width="175" \/><span>Learn your risk for heart disease<\/span><\/a>'		break;			}	document.write('<div>' + promo + '<\/div>');}