/***********************************************
* DHTML slideshow script-  © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice must stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
if (!(/MSIE/.test(navigator.userAgent)) && navigator.product == "Gecko") {
	HTMLElement.prototype.__defineSetter__("outerHTML", function (sHTML) {
	   var r = this.ownerDocument.createRange();
	   r.setStartBefore(this);
	   var df = r.createContextualFragment(sHTML);
	   this.parentNode.replaceChild(df, this);

	   return sHTML;
	});
}
var photos=new Array();
var boxtext=new Array();
var photoslink=new Array();
var which=0;

//define images.
photos[0]="images/walker.jpg";
photos[1]="images/sharma.jpg";
photos[2]="images/margolis.jpg";
photos[3]="images/meyer.jpg";
photos[4]="images/fitzig.jpg";
photos[5]="images/ogilvie-mcdaniel.jpg";
photos[6]="images/teck.jpg";
photos[7]="images/jacque_stearns.jpg";

boxtext[0] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Compassionate Care</h2><p>I really see my patients as heroes. I chose this specialty because I wanted to help people preserve and restore their function and mobility. I can&#8217;t imagine doing anything else.</p><p><strong>Damion Walker, DO</strong><br /><em>Orthopedics - Trauma </em><br /><em> Wichita Clinic - Founders&#8217; Circle</em></p></div>";
boxtext[1] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Comprehensive Care</h2><p>I am proud to be part of a team of 160 extremely competent physicians working together in 40 different specialties to provide comprehensive care to patients. The Clinic uses cutting edge technologies to provide the best and most efficient care to patients.</p><p><strong>Richa Sharma, MD</strong><br /><em>Internal Medicine</em><br/><em> Wichita Clinic - Murdock</em><br /></p></div>";
boxtext[2] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Collaborative Care</h2><p>I am proud to join Wichita Clinic&#8217;s growing Cardiology care team. The opportunity to add my services to our department allows us to provide all cardiovascular services in house, and helps us provide the best management of our patients&#8217; heart health.</p><p><strong>P. David Margolis, MD FACC</strong><br /><em>Cardiac Electrophysiology</em><br/><em>Wichita Clinic - Murdock</em><br /></p></div>";
boxtext[3] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Compassionate Care</h2><p>I focus on making the patient in front of me the most important person in the world. For the time that I am interacting with my patient, their ailments are my priority and their fears are held in my heart.  The rest of the world is forgotten until I leave that room.</p><p><strong>Alice Meyer, MD</strong><br /><em>Family Medicine</em><br/><em>Wichita Clinic - Augusta</em><br /></p></div>";
boxtext[4] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Cutting-Edge Technology</h2><p>Robot-assisted prostate surgery is minimally invasive and usually results in less blood loss and a quicker recovery time for my patients. They&#8217;ve been very pleased with their results and it&#8217;s exciting to be part of important technological advances at our major hospitals.</p><p><strong>Sanford Fitzig, MD</strong><br /><em>Urology</em><br/><em>Wichita Clinic - Murdock</em><br /></p></div>";
boxtext[5] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Compassionate Care</h2><p>I enjoy caring for and educating children. Laughing with my patients and their families is one of the most rewarding things about being a doctor.</p><p><strong>Chrishana Ogilvie-McDaniel, MD</strong><br /><em>Pediatric Allergy & Asthma </em><br/><em> Wichita Clinic - Murdock</em></p></div>";
boxtext[6] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Collaborative Care</h2><p>Our teamwork helps us provide comprehensive and efficient care for our patients. Investing in new technology (like electronic medical records and e-script) demonstrates our competitive edge in providing the best care for our patients.</p><p><strong>Angel Teck, DO</strong><br /><em>Family Medicine </em><br/><em> Wichita Clinic - Bethel-Newton</em></p></div>";
boxtext[7] = "<div id='boxtext' style='padding: 10px 0px 10px 20px;'><h2>Convenience</h2><p>E-Script makes it easy for your Clinic physicians to transmit your prescription straight to our fax machine and speed up processing and delivery. Our full-service pharmacy also offers <em><a href='http://www.wichitaclinic.com/Specialties_and_Services/Other_Services/Pharmacy/Online_Prescription_Refill.php'>online prescription refill</a></em>, a drive-through window, delivery to your home or office, and mailing services.</p><p><em>Pharmacy</em><br /><em>Wichita Clinic - Murdock</em></p></div>";

//Specify whether images should be linked or not (1=linked)
var linkornot=0;

//Set corresponding URLs, width and height for links in a new window
//for each of above images. Define ONLY if variable linkornot equals "1"
photoslink[0]=["http://www.google.com/", 300, 250];
photoslink[1]=["http://www.yahoo.com/", 500, 100];
photoslink[2]=["http://www.dynamicdrive.com/", 375, 200];

//do NOT edit pass this line

var preloadedimages=new Array()
for (i=0;i<photos.length;i++){
preloadedimages[i]=new Image()
preloadedimages[i].src=photos[i]
}

function applyeffect(){
if (document.all && photoslider.filters){
photoslider.filters[0].Stop()
photoslider.filters[0].Apply()
//alert(boxtext)
}
//if (document.all && document.getElementById('boxtext').filters) {
//document.getElementById('boxtext').filters[0].Stop()
//document.getElementById('boxtext').filters[0].Apply()
//}
}

function playeffect(){
if (document.all && photoslider.filters)
photoslider.filters[0].Play();
//if (document.all && document.getElementById('boxtext').filters)
//document.getElementById('boxtext').filters[0].Play();
}

function keeptrack(){
window.status="Image "+(which+1)+" of "+photos.length
}

function backward(){
clearTimeout(moving);
which=which>0? which-1 : photos.length-1
applyeffect()
document.images.photoslider.src=photos[which]
document.getElementById('boxtext').outerHTML = boxtext[which]
playeffect()
keeptrack()
moving=setTimeout("forward2()",9000)
}

function forward(){
clearTimeout(moving);
which=which<photos.length-1? which+1 : 0
applyeffect()
document.images.photoslider.src=photos[which]
document.getElementById('boxtext').outerHTML = boxtext[which]
playeffect()
keeptrack()
moving=setTimeout("forward2()",9000)
}

function forward2(){
clearTimeout(moving);
which=which<photos.length-1? which+1 : 0;
applyeffect();
document.images.photoslider.src=photos[which];
document.getElementById('boxtext').outerHTML = boxtext[which];
playeffect();
keeptrack();
moving=setTimeout("forward2()",9000);
}

function transport(){
window.open(photoslink[which][0],'','width='+photoslink[which][1]+', height='+photoslink[which][2])
}

function move(){
setTimeout("keeptrack()",20);
moving=setTimeout("forward2()",9000)
}

onload=move;
