// JavaScript Document
var tot_rec_adv = "4";
var texts_adv = new Array(tot_rec_adv);
texts_adv[0] = '<table width="100%" border="0" cellspacing="0" cellpadding="0" align="left" valign="top"><tr><td width="50" rowspan="3" class="testimonials_text" style="padding-right:10px" align="left" valign="middle" ><a href="testimonials.php#hariharakrishnan"><img src="images/testimonials_image.gif" alt="Kapleshwar Optics - Testimonials"  width="49" height="48" border="0" /></a></td><td align="left" valign="top"><a href="testimonials.php#hariharakrishnan" class="lightbox_txt">Mr. Hariharakrishnan - <span class="orange_txt">Chartered Accountant</span></a> </td></tr><tr><td height="5" align="left" valign="top"></td></tr><tr><td class="white_txt" align="left" valign="top" >&quot;At Kapleshwar Optics, I am convinced of the quality, the service and even when there is a mistake on my part, you are there to rectify it.&quot;</td></tr></table>';
texts_adv[1] = '<table width="100%" border="0" cellspacing="0" cellpadding="0" align="left" valign="top"><tr><td width="50" rowspan="3" class="testimonials_text" style="padding-right:10px" align="left" valign="middle"  ><a href="testimonials.php#sathishkrishnan"><img src="images/testimonials_image1.gif" alt="Kapleshwar Optics - Testimonials" width="49" height="48" border="0" /></a></td><td align="left" valign="top"><a href="testimonials.php#sathishkrishnan" class="lightbox_txt">Sathish Krishnan - <span class="orange_txt">Associate Director, P&G.Singapore</span></a></td></tr><tr><td height="5" align="left" valign="top"></td></tr><tr><td class="white_txt" align="left" valign="top">&quot;I have been out of chennai for 10 years now, but have never bought a pair of spectacles at any place other than Kapleshwar Optics.&quot;</td></tr></table>';
texts_adv[2] = '<table width="100%" border="0" cellspacing="0" cellpadding="0" align="left" valign="top"><tr><td width="50" rowspan="3" class="testimonials_text" style="padding-right:10px" align="left" valign="middle"  ><a href="testimonials.php#murthy"><img src="images/murthy.gif" alt="Kapleshwar Optics - Testimonials" width="49" height="48" border="0" /></a></td><td align="left" valign="top"><a href="testimonials.php#murthy" class="lightbox_txt">Mr. R.V.R Murthy<span class="orange_txt"></span></a></td></tr><tr><td height="5" align="left" valign="top"></td></tr><tr><td class="white_txt" align="left" valign="top">&quot;Kapleshwar Optics eye care gives you the optimum comfort and makes you feel like a real new person with the spectacles in front of everyone. Also, the standards of this opticals is top end.&quot;</td></tr></table>';
texts_adv[3] = '<table width="100%" border="0" cellspacing="0" cellpadding="0" align="left" valign="top"><tr><td width="50" rowspan="3" class="testimonials_text" style="padding-right:10px" align="left" valign="middle"  ><a href="testimonials.php#rajamani_murthy"><img src="images/rajamani.gif" alt="Kapleshwar Optics - Testimonials" width="49" height="48" border="0" /></a></td><td align="left" valign="top"><a href="testimonials.php#rajamani_murthy" class="lightbox_txt">Mrs. Rajamani Murthy<span class="orange_txt"> </span></a></td></tr><tr><td height="5" align="left" valign="top"></td></tr><tr><td class="white_txt" align="left" valign="top">&quot;Kapleshwar Optics has got the best after sales service. Wearing spectacles from Kapleshwar Optics transforms the person by giving a new look. The return on investment is very high (maximum).&quot;</td></tr></table>';
window.onload = oncall;
var interval_adv = 10000;
function rotate2(step)
{
	if( step == undefined || step==null || step=="[object Event]")
	{
		step = 1;
	}
	step = parseInt(step);
	if(tot_rec_adv < 1)
	{
		if(texts_adv[0]==0)
		{
			document.getElementById('test_rot_id').innerHTML = "&lt;span class='poll_head'&gt;No Testimonials&lt;/span&gt;";
		}
	}
	else
	{
		document.getElementById('test_rot_id').innerHTML = texts_adv[step-1];
		step++;
		if(step <= tot_rec_adv)
		{
			setTimeout("fadein("+step+")",interval_adv);
		}
		else
		{
			setTimeout("fadein(1)",interval_adv);
		}
	}
}
function fadein(step,opac)
{
	var out_n = "test_rot_id";
	if(opac == undefined || opac == null || opac == "")
	{
		opac = 100;
	}
	opac = parseInt(opac);
	document.getElementById(out_n).style.background = "";
	document.getElementById(out_n).style.filter = "progid:DXImageTransform.Microsoft.alpha(opacity="+opac+")";
	var x = opac / 101;
	document.getElementById(out_n).style.opacity = x;
	document.getElementById(out_n).style.MozOpacity = x;
	document.getElementById(out_n).style.KhtmlOpacity = x;
	opac = opac - 20;
	if(opac > 0)
	{
		var func = "fadein('"+step+"',"+opac+")";
		setTimeout(func,100);
	}
	else
	{
		fadeout(step);
	}
}
function fadeout(step)
{
	var out_n = "test_rot_id";
	document.getElementById(out_n).style.background = "";
	document.getElementById(out_n).style.filter = "";
	document.getElementById(out_n).style.opacity = "";
	document.getElementById(out_n).style.MozOpacity = "";
	document.getElementById(out_n).style.KhtmlOpacity = "";
	rotate2(step);
}
function oncall()
{
	if(typeof window.rotate == 'function') {
		rotate(1);
	}
	if(typeof window.rotate2 == 'function') {
		rotate2(1);
	}
	if(typeof window.rotate2_poll == 'function') {
		rotate2_poll(1);
	}
}

