/***********************************************
* Simple Controls Gallery- (c) Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for this script and 100s more
* http://www.dynamicdrive.com/dynamicindex4/simplegallery.htm
* http://www.dynamicdrive.com/dynamicindex4/simplegallery_suppliment.htm
***********************************************/

var promotionbox=new simpleGallery({
	wrapperid: "promotion", //ID of main gallery container,
	dimensions: [400, 300], //width/height of gallery in pixels. Should reflect dimensions of the images exactly the images are housed in /images/promotion/ , remember to change the  google tracking source so it is specific to the campaign
	imagearray: [
	

		
		["/study/science-courses/dentistry/images/slideshow-facilities/Oral-Health-Therapy-class-1.jpg", false, "", {alt:"Lab with students", title:"Lab with students"}],
			
			["/study/science-courses/dentistry/images/slideshow-facilities/Oral-Health-Therapy-class-2.jpg", false, "", {alt:"Dental chair/dream clinic", title:"Dental chair/dream clinic"}],	
			
["/study/science-courses/dentistry/images/slideshow-facilities/Oral-Health-Therapy-class-3.jpg", false, "", {alt:"Lecture theatre", title:"Lecture theatre"}],

["/study/science-courses/dentistry/images/slideshow-facilities/Orange0809-2.jpg", false, "", {alt:"Front of building", title:"Front of building"}],
["/study/science-courses/dentistry/images/slideshow-facilities/WW-front.jpg", false, "", {alt:"Front of building", title:"Front of building"}],
["/study/science-courses/dentistry/images/slideshow-facilities/WW-Teaching-2.jpg", false, "", {alt:"Breakout rooms", title:"Breakout rooms"}],
["/study/science-courses/dentistry/images/slideshow-facilities/equipment.jpg", false, "", {alt:"Equipment", title:"Equipment"}],
["/study/science-courses/dentistry/images/slideshow-facilities/equipment-2.jpg", false, "", {alt:"Equipment", title:"Equipment"}]



],
	defaultattr: {alt:"",title:""}, //alt and title for images without a specified alt/title. Required.
	autoplay: true,
	persist: false,
	pause: 3000, //pause between slides (milliseconds)
	fadeduration: 700, //transition duration (milliseconds)
	oninit:function(){ //event that fires when gallery has initialized/ ready to run
	},
	onslide:function(curslide, i){ //event that fires after each slide is shown
		//curslide: returns DOM reference to current slide's DIV (ie: try alert(curslide.innerHTML)
		//i: integer reflecting current image within collection being shown (0=1st image, 1=2nd etc)
	}
})

/***********************************************
Change classname of tabs to active/inactive
***********************************************/

function toggle(linkObj)
{
	var node = linkObj; //start
	while (node && node.nodeName.toUpperCase() != 'UL') //node exists, isn't UL
		node = node.parentNode; //go up
	var tabs = node.getElementsByTagName('a'), //got it, get collection
	tab,
	t = 0;
	while (tab = tabs[t++])
		if (tab == linkObj)
			tab.className = 'active';
		else tab.className = 'inactive';
	return false;
}

