/*

Image rotator for Crosstex Energy
Version:	1.0
Created:	2007-11-11
Auth:		Andrew Hamel - torque FKM

b_headline
b_text
b_link
b_link_title
b_image

*/

var i = 0;
var c = new Array();
var t = '';

function doimg(){
	if(i == c.length){ i = 0; }
	document.getElementById("b_headline").innerHTML = c[i].headline;
	document.getElementById("b_text").innerHTML = c[i].text;
	t = c[i].url;
	document.getElementById("b_link_title").innerHTML = c[i].label;
	document.getElementById("b_image").innerHTML = '<img src="images/rotator/'+ c[i].img +'" width="285">';
	i++;
}

function jump(){
	document.location.href = t;	
}


/*

!!!!!!!!!   EDIT ABOVE THIS LINE AT YOUR OWN RISK   !!!!!!!!!

*/

// populate with content
c[0] = {
	headline: 'Delivering Success',
	text: 'Crosstex is the premier midstream energy services company. We provide the full spectrum of services that move natural gas from the wellhead to the burner tip.',
	url: 'aboutus.html',
	label: 'Learn more about Crosstex',
	img: 'img5.jpg'
}

c[1] = {
	headline: 'Great People Wanted',
	text: 'Looking to be part of a company focused on the future?  We\'re looking for you.',
	url: 'careers.html',
	label: 'Choose a Crosstex career',
	img: 'img1.jpg'
}

c[2] = {
	headline: 'Unmatched Expertise',
	text: 'Whatever your needs, Crosstex has the expertise to provide the most cost-effective solution and the ability to do it quickly.',
	url: 'services.html',
	label: 'Learn more about our services',
	img: 'img2.jpg'
}

c[3] = {
	headline: 'Caring Neighbors',
	text: 'Crosstex is committed to make a positive impact in the communities in which we live and work.',
	url: '/community/involvement.html',
	label: 'See how we make a difference',
	img: 'img3.jpg'
}


c[4] = {
	headline: 'Safety First',
	text: 'Crosstex\'s award-winning safety record speaks for itself.',
	url: '/about/environment.html',
	label: 'Find out more',
	img: 'img7.jpg'
}



/*

To change the frequency at which content rotates, change the numeric value.
It is in milliseconds of which each second has 1000.  Ex.:  2 seconds  = 2000

*/

setInterval(doimg, 8000);