//language converter
browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);
condition = !(( (browserName.indexOf("Explorer") >=0 ) && (browserVer < 4) ) ||  ((browserName.indexOf("Netscape") >=0 ) && (browserVer < 2) ) ) ;
if (condition == true  )
    CanAnimate = true;
else
    CanAnimate = false;
function convertnew(pattern)
{
	/// Configuration parameters //////////////
	var open_in_same_window = 0;
	//////////// End Of Configuration /////////////
	var my_location = unescape(document.location.toString());
	var new_location ='';
	var new_pattern = '';
	if (my_location.indexOf('translate_c?') != -1) {
		/// From google...
		var indexof_u = my_location.indexOf('u=');
		if (indexof_u == -1) {
			new_location = document.location;
		}
		else {
			var subs = my_location.substring(indexof_u, my_location.length);
			var ss = subs.split('&');
			new_location = ss[0].substring(2, ss[0].length);
		}
	}
	else {
		new_location = document.location;
	}

	indexof_p = pattern.indexOf('|');

	var isen = '';
	if (indexof_p == -1) {
		indexof_p1 = pattern.indexOf('><');
		if (indexof_p1 == -1) {
			new_pattern = pattern;
			if (pattern == 'en') {
				isen = 1;
			}
		}
		else {
			var psplit =pattern.split('><');
			new_pattern = psplit[0]+'|'+psplit[1];
			if (psplit[1] == 'en') {
				isen = 1;
			}
		}
	}
	else {
		var psplit = pattern.split('|');
		new_pattern = psplit[0]+'|'+psplit[1];
		if (psplit[1] == 'en') {
			isen = 1;
		}
	}
	var thisurl = '';
	if (isen == 1) {
		thisurl = new_location;
	}
	else {
		thisurl = 'http://translate.google.com/translate_c?langpair=' + new_pattern + "&u=" + new_location;
	}

	if (open_in_same_window == 1) {
		window.location.href = thisurl;
	}
	else {
		if (CanAnimate ){
			msgWindow=window.open('' ,'subwindow','toolbar=yes,location=yes,directories=yes,status=yes,scrollbars=yes,menubar=yes,resizable=yes,left=0,top=0');
			msgWindow.focus();
			msgWindow.location.href = thisurl;
		}
		else {
			msgWindow=window.open(thisurl,'subwindow','toolbar=yes,location=yes,directories=yes,status=yes,scrollbars=yes,menubar=yes,resizable=yes,left=0,top=0');
		}
	}
}
//Motion Pack
var timerlen = 5;
var slideAniLen = 250;
var timerID = new Array();
var startTime = new Array();
var obj = new Array();
var endHeight = new Array();
var moving = new Array();
var dir = new Array();
//language converter Ends
//Subscribe NEWSLETTER Starts
function validateit(theForm) {
	if(theForm.nl_name.value == 'Your name here')
	{
		alert("Kindly enter your name.");
		theForm.nl_name.focus();
		return false;
	}
	if(theForm.email.value == 'Your e-mail here')
	{
		alert("Kindly enter your e-mail.");
		theForm.email.focus();
		return false;
	}
	if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(theForm.email.value)))
	{
		alert("Invalid Email ID. Kindly enter the correct ID.");
		theForm.email.focus();
		return (false);
	}
}
function openchild_nl(thisurl)
{
	browserName = navigator.appName;
	browserVer = parseInt(navigator.appVersion);
	condition = !(( (browserName.indexOf("Explorer") >=0 ) && (browserVer < 4) ) ||  ((browserName.indexOf("Netscape") >=0 ) && (browserVer < 2) ) ) ;
	if (condition == true)
		CanAnimate = true;
	else
		CanAnimate = false;
	var nl_name = document.theForm.nl_name.value;
	var nl_grp_id = document.theForm.nl_grp_id.value;
	var email_val = document.theForm.email.value;
	var from_site_val = document.theForm.from_site.value;
	var is_window_val = document.theForm.is_window.value;
	var org_referer = document.theForm.org_referer.value;
	var is_im = document.theForm.is_im.value;
	var thisurl_string = thisurl + "?email=" + email_val + "&from_site=" + from_site_val + "&is_window=" + is_window_val + "&org_referer=" + org_referer + "&is_im=" + is_im + "&nl_name=" + nl_name + "&nl_grp_id=" + nl_grp_id;
	if ( CanAnimate ){
			msgWindow=window.open( '' ,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=550,height=340,top=0,left=0');
			msgWindow.focus();msgWindow.location.href = thisurl_string;
		}
	else {
		msgWindow=window.open( thisurl_string,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=550,height=340,top=0,left=0');}
	}
function getf(Form){if(Form.email.value==''){Form.email.value='Your e-mail here';Form.email.className="i1";}}
function getblank(Form){if(Form.email.value=='Your e-mail here'){Form.email.value='';Form.email.className="i3";}}
function getf1(Form){if(Form.nl_name.value==''){Form.nl_name.value='Your name here';Form.nl_name.className="i1";}}
function getblank1(Form){if(Form.nl_name.value=='Your name here'){Form.nl_name.value='';Form.nl_name.className="i3";}}
//Subscribe NEWSLETTER End
function check_blank()
{
	if(document.b_frm.ss.value == '')
	{
		alert("Please fill the city name.");
		document.b_frm.ss.focus();
		return false;
	}
}
// Hotel Booking JS Starts
function addzero( value )
{
while( value.length<2 ) value = String("0") + value;
return value;
}
function bkdates()
{
 var monthArray=new Array("January","February","March","April","May","June","July","August","September","October","November","December");
var today = new Date();
var month= today.getMonth();
var year = today.getFullYear()%100;
var fullYear=today.getFullYear();
year=new String(year);
year=addzero(year);
var countMonth=month;
for(var i=0;i<12;i++,countMonth++){
if(countMonth%12==0 && i>0){
countMonth=0;
year++;
year=new String(year);
year=addzero(year);
fullYear++;
}
document.writeln("<option value=\""+fullYear+"-"+(countMonth+1)+"\">"+monthArray[countMonth]+" '"+year);
}
}
function bkdates1()
{
 var monthArray=new Array("January","February","March","April","May","June","July","August","September","October","November","December");
var today = new Date();
var month= today.getMonth();
var year = today.getFullYear()%100;
var fullYear=today.getFullYear();
year=new String(year);
year=addzero(year);
var countMonth=month;
document.writeln('<SELECT ID="b_checkin_month" NAME="checkin_year_month" CLASS="fs">')
for(var i=0;i<12;i++,countMonth++){
if(countMonth%12==0 && i>0){
countMonth=0;
year++;
year=new String(year);
year=addzero(year);
fullYear++;
}
document.writeln("<option value=\""+fullYear+"-"+(countMonth+1)+"\">"+monthArray[countMonth]+" '"+year);
}
document.writeln('</SELECT>')

}function bkdates2()
{
 var monthArray=new Array("January","February","March","April","May","June","July","August","September","October","November","December");
var today = new Date();
var month= today.getMonth();
var year = today.getFullYear()%100;
var fullYear=today.getFullYear();
year=new String(year);
year=addzero(year);
var countMonth=month;
document.writeln('<SELECT ID="b_checkout_month" NAME="checkout_year_month" CLASS="fs">')
for(var i=0;i<12;i++,countMonth++){
if(countMonth%12==0 && i>0){
countMonth=0;
year++;
year=new String(year);
year=addzero(year);
fullYear++;
}
document.writeln("<option value=\""+fullYear+"-"+(countMonth+1)+"\">"+monthArray[countMonth]+" '"+year);
}
document.writeln('</SELECT>')
}






function bkhotel(){
var currentDate = new Date(); var currentYear = 1900 + currentDate.getYear();
var dailyMS = 24*60*60*1000;
var arrivalDate = new Date(currentDate.getTime());
var departureDate = new Date(currentDate.getTime() + 1*dailyMS);
var arrivalYear = 1900+arrivalDate.getYear(); 
var arrivalMonth = 1+arrivalDate.getMonth(); var arrivalDay = arrivalDate.getDate();
var departureYear = 1900+departureDate.getYear(); 
var departureMonth = 1+departureDate.getMonth(); var departureDay = departureDate.getDate();
var a=document.b_frm;
if ((a.checkin_monthday.selectedIndex == 0) && (a.checkout_monthday.selectedIndex == 0)){
    a.checkin_monthday.options[arrivalDay].selected = true;
    a.checkout_monthday.options[departureDay].selected = true;
}
var frm = document.getElementById('b_frm');
var my = frm['b_checkin_month'].value.split("-");
var ci = new Date (my[0], my[1]-1, frm['b_checkin_day'].value, 12, 0, 0, 0);
my = frm['b_checkout_month'].value.split("-");
var co = new Date (my[0], my[1]-1, frm['b_checkout_day'].value, 12, 0, 0, 0);
if (ci >= co){
co.setTime(ci.getTime() + 1000 * 60 * 60 * 24);
frm['b_checkout_day'].value =  co.getDate();
var com = co.getMonth()+1;
frm['b_checkout_month'].value = co.getFullYear() + "-" + com;
}
}
function getDropDown()
{
	for(var i=0;i<=31;i++)
	{
		document.writeln("<option value=\""+i+"\">"+i);
	}
}
function getDropDown1()
{

document.writeln('<SELECT ID="b_checkin_day" NAME="checkin_monthday" CLASS="fs">')
	for(var i=1;i<=31;i++)
	{
		document.writeln("<option value=\""+i+"\">"+i);
	}
document.writeln('</SELECT>')
}
function getDropDown2()
{
document.writeln(' <SELECT ID="b_checkout_day" NAME="checkout_monthday" CLASS="fs">')
	for(var i=1;i<=31;i++)
	{
		document.writeln("<option value=\""+i+"\">"+i);
	}
document.writeln('</SELECT>')
}
function showHiddenFields(cityname,countryflname,cityflname,grpflname,eventflname,countryname,grpname,eventname)
{
	document.writeln("<input name=\"error_url\" value=\"http://www.booking.com/index.en.html?aid=325394&amp;label=&amp;\" type=\"hidden\"><input name=\"si\" value=\"ci\" type=\"hidden\"><input name=\"ssai\" value=\"1\" type=\"hidden\"><input name=\"ssre\" value=\"1\" type=\"hidden\"><input id=\"availcheck\" name=\"do_availability_check\" value=\"on\" type=\"hidden\"><input name=\"aid\" value=\"325394\" type=\"hidden\"><input name=\"lang\" value=\"en\" type=\"hidden\"><input name=\"ifl\" value=\"1\" type=\"hidden\"><input name=\"label\" value=\"\" type=\"hidden\"><input name=\"ss\" value=\""+cityname+"\" type=\"hidden\"><INPUT TYPE=\"HIDDEN\" NAME=\"country_flname\" VALUE=\""+countryflname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"city_flname\" VALUE=\""+cityflname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"grp_flname\" VALUE=\""+grpflname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"event_flname\" VALUE=\""+eventflname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"country_name\" VALUE=\""+countryname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"city_name\" VALUE=\""+cityname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"grp_name\" VALUE=\""+grpname+"\"><INPUT TYPE=\"HIDDEN\" NAME=\"event_name\" VALUE=\""+eventname+"\">");
}
function check_advanced_search()
{
	var kw = document.searc.q.value;
	kw = kw.replace(/^\s+|\s+$/g,"");
	if (kw.length < 3)
	{
		error_message = "Please enter atleast 3 characters for search";
		alert(error_message);
		document.searc.q.focus();
		return false;
	}
	return true;
}
function check_advanced_search1()
{
	var kw = document.searc1.q.value;
	kw = kw.replace(/^\s+|\s+$/g,"");
	if (kw.length < 3)
	{
		error_message = "Please enter atleast 3 characters for search";
		alert(error_message);
		document.searc1.q.focus();
		return false;
	}
	return true;
}
//Media4Trade js starts
var mediaserver_height="";
var mediaserver_width="";
var mediaserver_location="";
var mediaserver_contenttype="";
var mediaserver_id="";
var mediaserver_uname="";
var mediaserver_comp="";
var mediaserver_mcat="";
var mediaserver_cat="";
var mediaserver_grp="";
var mediaserver_cmpg="";
var mediaserver_kwd="";
var mediaserver_otherparam="";
var mediaserver_nomore=0;
var mediaserver_noadv=0;
var mediaserver_newwin=0;
var mediaserver_paidonly=0;
var mediaserver_useiframe=0;
var mediaserver_parentwindow=0;
function serve_ad(mycompid)
{
	var mediaserver_ad_url = 'http://www.media4trade.com/mediaserver?';
	var mediaserver_size = mediaserver_width+'x'+mediaserver_height;
	
	var mediaserver_pageurl;
	if(mediaserver_parentwindow == 1)
	{
		mediaserver_pageurl = parent.document.location;
	}
	else
	{
		mediaserver_pageurl = document.location;
	}
	mediaserver_ad_url += 'action=show';
	mediaserver_ad_url += '&pageurl=' + encodeURIComponent(mediaserver_pageurl);
	mediaserver_ad_url += '&location=' + mediaserver_location;
	mediaserver_ad_url += '&kwd=' + encodeURIComponent(mediaserver_kwd);
	mediaserver_ad_url += '&size=' + mediaserver_size;
	mediaserver_ad_url += '&contenttype=' + mediaserver_contenttype;
	mediaserver_ad_url += '&id=' + mediaserver_id;
	mediaserver_ad_url += '&uname=' + mediaserver_uname;
	if(mycompid)
	{
		mediaserver_ad_url += '&comp=' + mycompid;
	}
	else
	{
		mediaserver_ad_url += '&comp=' + mediaserver_comp;
	}
	mediaserver_ad_url += '&mcat=' + mediaserver_mcat;
	mediaserver_ad_url += '&cat=' + mediaserver_cat;
	mediaserver_ad_url += '&grp=' + mediaserver_grp;
	mediaserver_ad_url += '&cmpg=' + mediaserver_cmpg;
	mediaserver_ad_url += '&otherparam=' + encodeURIComponent(mediaserver_otherparam);
	mediaserver_ad_url += '&nomore=' + mediaserver_nomore;
	mediaserver_ad_url += '&noadv=' + mediaserver_noadv;
	mediaserver_ad_url += '&newwin=' + mediaserver_newwin;
	mediaserver_ad_url += '&paidonly=' + mediaserver_paidonly;
	if(mediaserver_contenttype == 'prdbanner') {mediaserver_noadv = 1;}
	if(mediaserver_useiframe)
	{
		if(!mediaserver_noadv)
		{
			mediaserver_height = parseInt(mediaserver_height)+20;
		}

		mediaserver_ad_url += '&iframe=1';
		document.write('<center><ifr'+'ame id="'+mediaserver_location+'" src="' + mediaserver_ad_url + '" width="'+mediaserver_width+'" height="'+mediaserver_height+'" frameborder="0" scrolling="no" marginwidth="0" marginheight="0" target="_top"></ifr'+'ame></center>');
	}
	else
	{
		mediaserver_ad_url += '&iframe=0';
		document.write('<center><scr'+'ipt type="text/javascript" src="' + mediaserver_ad_url + '"></scr'+'ipt></center>');
	}
}

//Media4Trade js ends
//google-custom-ad31.js Starts
function google_ad_request_done(google_ads) {
/*This function is required and is used to display the ads that are returned from the JavaScript request.
You should modify the document.write commands so that the HTML they write out fits with your desired ad layout.	*/
//alert(whichad);
	var s = '',i;
//Verify that there are actually ads to display.

if (google_ads.length == 0) {return;}

/*If an image or flash ad is returned, display that ad. Otherwise, build a string containing all of the ads and
then use a document.write() command to print that string.*/
if (google_ads[0].type == "html") {
s += google_ads[0].snippet;
} else {
		s += '<DIV><a href=\"' + google_info.feedback_url + '\" style="font:bold 11px arial; color:#555;text-decoration:none; padding:0 0 0 5px" target="_blank">Ads by Google</a></DIV><DIV style="background-color:#ffffff;padding:5px 5px 5px 0;line-height:15px;">'
			for(i = 0; i < google_ads.length; ++i) {
			if(i>0)
			{
				s += '<BR>';
			}
if(whichad=="top")
	{
			s += '<a style="font-family:arial;font-size:13px; color:#1072BD; font-weight:bold;margin-top:3px;" target="_blank" class="tu" href="' +
			google_ads[i].url + '" onmouseout="window.status=\'\'" onmouseover="window.status=\'go to ' +
			google_ads[i].visible_url + '\';return true">' +
			google_ads[i].line1 + '</a><br><span><a style="font-family:arial;font-size:12px;color:#333;" class="tn" target="_blank" href="' +
			google_ads[i].url + '" onmouseout="window.status=\'\'" onmouseover="window.status=\'go to ' +
			google_ads[i].visible_url + '\';return true">' +
			google_ads[i].visible_url + '</span></a> <span style="font-family:arial; font-size:12px; color:#333333;">' +
			google_ads[i].line2 + ' ' +
			google_ads[i].line3 + '<BR></span>';
			}else{
			s += '<a class="gdc" style="font-family:arial;font-size:13px; font-weight:normal;margin-top:3px; text-decoration:none" target="_blank" href="' +
			google_ads[i].url + '" onmouseout="window.status=\'\'" onmouseover="window.status=\'go to ' +
			google_ads[i].visible_url + '\';return true">' +
			google_ads[i].line1 + '</a><br><span style="font-family:arial; font-size:12px; color:#333333;">' +
			google_ads[i].line2 + ' ' +
			google_ads[i].line3 + '<BR></span> <span><a style="font-family:arial;font-size:12px;color:#333;" class="tn" target="_blank" href="' +
			google_ads[i].url + '" onmouseout="window.status=\'\'" onmouseover="window.status=\'go to ' +
			google_ads[i].visible_url + '\';return true">' +
			google_ads[i].visible_url + '</span></a><br>';
		}
	}
			s += '</DIV>';
			if (google_ads[0].bidtype == "CPC")
			{
				/* insert this snippet for each ad call */
				google_adnum = google_adnum + google_ads.length;
			}
	}
    document.write(s);
    return;
}

function gl()
{
google_ad_client = 'pub-8525015516580200'; // substitute your client_id (pub-#)
google_ad_channel = ad_channel;
google_ad_output = 'js';
google_max_num_ads = ads_count;
google_ad_type = 'text';
google_feedback = 'on';
// google_skip = google_skip;
//google_skip = google_adnum; /* insert this snippet for each ad call */
}
//google-custom-ad31.js Ends







function submitPaginationForm(i)
{
	document.pagination.p.value = i;
	document.pagination.submit();
}
function toggleSlide(a){if(document.getElementById(a).style.display=="none"){slidedown(a)}else{slideup(a)}}var TINY={};function T$(a){return document.getElementById(a)}TINY.box=function(){var a,g,l,k,c,i,h,n,e,j=0;return{show:function(s,o,m,r,f,q){if(!j){a=document.createElement("div");a.id="tinybox";g=document.createElement("div");g.id="tinymask";l=document.createElement("div");l.id="tinycontent";document.body.appendChild(g);document.body.appendChild(a);a.appendChild(l);j=1}if(!f&&!o){a.style.width=m?m+"px":"auto";a.style.height=r?r+"px":"auto";a.style.backgroundImage="none";l.innerHTML=s}else{l.style.display="none";a.style.width=a.style.height="100px"}this.mask();c=s;i=o;h=m;n=r;e=f;this.alpha(g,1,80,3)},fill:function(s,q,o,r,m){if(q){a.style.backgroundImage="";var f=window.XMLHttpRequest?new XMLHttpRequest():new ActiveXObject("Microsoft.XMLHTTP");f.onreadystatechange=function(){if(f.readyState==4&&f.status==200){TINY.box.psh(f.responseText,o,r,m)}};f.open("GET",s,1);f.send(null)}else{this.psh(s,o,r,m)}},psh:function(s,o,q,m){if(m){if(!o||!q){var f=a.style.width,r=a.style.height;l.innerHTML=s;a.style.width=o?o+"px":"";a.style.height=q?q+"px":"";l.style.display="";o=parseInt(l.offsetWidth);q=parseInt(l.offsetHeight);l.style.display="none";a.style.width=f;a.style.height=r}else{l.innerHTML=s}this.size(a,o,q,4)}else{a.style.backgroundImage="none"}},hide:function(){TINY.box.alpha(a,-1,0,3)},resize:function(){TINY.box.pos();TINY.box.mask()},mask:function(){g.style.height=TINY.page.theight()+"px";g.style.width="";g.style.width=TINY.page.twidth()+"px"},pos:function(){var f=(TINY.page.height()/2)-(a.offsetHeight/2);f=f<10?10:f;a.style.top=(f+TINY.page.top())+"px";a.style.left=(TINY.page.width()/2)-(a.offsetWidth/2)+"px"},alpha:function(o,q,f,m){clearInterval(o.ai);if(q==1){o.style.opacity=0;o.style.filter="alpha(opacity=0)";o.style.display="block";this.pos()}o.ai=setInterval(function(){TINY.box.twalpha(o,f,q,m)},20)},twalpha:function(q,f,t,m){var r=Math.round(q.style.opacity*100);if(r==f){clearInterval(q.ai);if(t==-1){q.style.display="none";q==a?TINY.box.alpha(g,-1,0,2):l.innerHTML=a.style.backgroundImage=""}else{q==g?this.alpha(a,1,100,5):TINY.box.fill(c,i,h,n,e)}}else{var u=r+Math.ceil(Math.abs(f-r)/m)*t;q.style.opacity=u/100;q.style.filter="alpha(opacity="+u+")"}},size:function(r,u,q,y){r=typeof r=="object"?r:T$(r);clearInterval(r.si);var f=r.offsetWidth,v=r.offsetHeight,t=f-parseInt(r.style.width),x=v-parseInt(r.style.height);var m=f-t>u?-1:1,o=(v-x>q)?-1:1;r.si=setInterval(function(){TINY.box.twsize(r,u,t,m,q,x,o,y)},20)},twsize:function(r,u,t,m,q,x,o,y){var f=r.offsetWidth-t,v=r.offsetHeight-x;if(f==u&&v==q){clearInterval(r.si);a.style.backgroundImage="none";l.style.display="block"}else{if(f!=u){r.style.width=f+(Math.ceil(Math.abs(u-f)/y)*m)+"px"}if(v!=q){r.style.height=v+(Math.ceil(Math.abs(q-v)/y)*o)+"px"}this.pos()}}}}();TINY.page=function(){return{top:function(){return document.body.scrollTop||document.documentElement.scrollTop},width:function(){return self.innerWidth||document.documentElement.clientWidth},height:function(){return self.innerHeight||document.documentElement.clientHeight},theight:function(){var f=document,a=f.body,c=f.documentElement;return Math.max(Math.max(a.scrollHeight,c.scrollHeight),Math.max(a.clientHeight,c.clientHeight))},twidth:function(){var f=document,a=f.body,c=f.documentElement;return Math.max(Math.max(a.scrollWidth,c.scrollWidth),Math.max(a.clientWidth,c.clientWidth))}}}();var http_request=false;var ajaxdata_div_id="ajaxdata";function createMyBox(e,c,g){var f=Math.max(Math.max(document.body.scrollHeight,document.documentElement.scrollHeight),Math.max(document.body.clientHeight,document.documentElement.clientHeight));var a=Math.max(Math.max(document.body.scrollWidth,document.documentElement.scrollWidth),Math.max(document.body.clientWidth,document.documentElement.clientWidth));bg_img=document.getElementById("bgimg");bg_img.height=f;bg_img.width=a;bg_img.style.display="block";bg_img.style.position="absolute";bg_img.style.zIndex="90";p=document.createElement("div");p.id="mybox";b=document.createElement("div");b.id="mycontent";document.body.appendChild(p);p.appendChild(b);p.style.position="absolute";p.style.top="0";p.style.left="40%";p.style.zIndex="90";p.style.width="100%";p.style.width=c?c+"px":"auto";p.style.height=g?g+"px":"auto";b.style.width=c?c+"px":"auto";b.style.height=g?g-20+"px":"auto";p.style.border="solid red 3px";callajax(e,"mycontent");p.innerHTML+='<a href="javascript:void(0);" ONCLICK="javascript:delMyBox();" style="float:right;">X</a>'}

function MM_openBrWindow(theURL,winName,features) { window.open(theURL,winName,'width=840,height=330');
}


function blow()
{
document.write('<DIV CLASS="doff" ALIGN="center" ID="message2" STYLE="top: 0px; left: 0px; z-index: 5000;"><div id="divheight" class="hnew"><img src="http://gifbt.com/gifs/zero.gif" height="1" width="1"><br></div><TABLE WIDTH="100%" CELLSPACING="0" CELLPADDING="0" BORDER="0" ID="tableheight" STYLE="width: 1002px; margin-top: 0px; height: 548px;"> <TR> <TD ALIGN="CENTER"><DIV CLASS="main4" ALIGN="CENTER"> <DIV CLASS="up-heada-1" ALIGN="CENTER"><A HREF="javascript:blowup_off()"><IMG src="/gifs/close.gif" ALIGN="RIGHT" WIDTH="21" HEIGHT="18" BORDER="0"></A><B ID="prname"></B></DIV> <DIV CLASS="main-tab" ALIGN="LEFT"><DIV ALIGN="CENTER" ID="video" CLASS="imdv"><DIV ID="loadimg" STYLE="font-family: arial; font-size: 15px;"><IMG src="/gifs/loading-2.gif"><BR> <BR> Loading...</DIV><DIV ID="imagediv" CLASS="doff" ALIGN="CENTER"></DIV></DIV><DIV CLASS="bgc" ALIGN="center"> <TABLE WIDTH="65%" ALIGN="CENTER" BORDER="0" CELLPADDING="0" CELLSPACING="0"><TR> <TD WIDTH="27%" ALIGN="CENTER"> <DIV CLASS="next" ID="pre"></DIV></TD> <TD ALIGN="CENTER" WIDTH="50%"><DIV ALIGN="CENTER" CLASS="viwe" ID="view"></DIV></TD> <TD WIDTH="23%" ALIGN="CENTER"> <DIV ID="next" CLASS="next"></DIV></TD> </TR> </TABLE> </DIV> </DIV><INPUT TYPE="hidden" NAME="products_id" ID="popup_proid" VALUE=""></DIV></TD> </TR> </TABLE> </DIV>');
}



var myWidth = 0, myHeight = 0;
function bhw() 
{
if( typeof( window.innerWidth ) == 'number' ) {
myWidth = window.innerWidth;
myHeight = window.innerHeight;
} else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    myWidth = document.documentElement.clientWidth;
    myHeight = document.documentElement.clientHeight;
  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
   myWidth = document.body.clientWidth;
   myHeight = document.body.clientHeight;
  }
var h = window.pageYOffset ||
document.body.scrollTop ||
document.documentElement.scrollTop;
var browserName=navigator.appName;var imagedivheight=myHeight-93;var test = myWidth*24/100;var divwidth = myWidth-test;var widthformizilla = myWidth-538;var mozillawidth = widthformizilla-divwidth;
var iewidth = myWidth-516;var mozillawidth1 = mozillawidth/2;var iewidth1 = iewidth/2;var mtop = h+7;var aboveheight = myHeight-584;var aboveheight1 = aboveheight/2+h;var tablew = myWidth-22;var intElemScrollHeight = document.getElementsByTagName('body')[0].scrollHeight;var newh = intElemScrollHeight;
document.getElementById('message2').style.width="100%";document.getElementById('message2').style.height=newh+"px";document.getElementById('tableheight').style.width=tablew+"px";document.getElementById('divheight').style.height=h+"px";document.getElementById('tableheight').style.marginTop="0px";document.getElementById('tableheight').style.height=myHeight+"px";}function blowup_show()
{document.getElementById('message2').className="blowupshow";
bhw();}function blowup_off()
{
document.getElementById('message2').className="doff";
if(document.getElementById('loadimg'))
{
document.getElementById('loadimg').className="don";
}
if(document.getElementById('imagediv'))
{
document.getElementById('imagediv').className="doff";
}
}
function getHTTPObject() { var xmlhttp;
  if(window.XMLHttpRequest){  xmlhttp = new XMLHttpRequest();
  }
  else if (window.ActiveXObject){
    xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
    if (!xmlhttp){
        xmlhttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
   
} return xmlhttp;
}
var http = getHTTPObject();  function getXMLHTTP() { 
		var xmlhttp=false;	
		try{
			xmlhttp=new XMLHttpRequest();
		}
		catch(e)	{		
			try{			
				xmlhttp= new ActiveXObject("Microsoft.XMLHTTP");
			}
			catch(e){
				try{
				xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
				}
				catch(e1){
					xmlhttp=false;
				}
			}
		}
		 	
		return xmlhttp;
	}





var path = '';
var imgid = "0";
var queryrfq = '';
function imageset(id,str)
{
document.getElementById('video').innerHTML='<DIV ID="loadimg" STYLE="font-family: arial; font-size: 15px;"><IMG src="/gifs/loading-2.gif"><BR> <BR> Loading...</DIV><DIV ID="imagediv" CLASS="doff" ALIGN="CENTER"></DIV>';
if(document.getElementById('allproducts_id'+id))
{
	if(document.getElementById('allproducts_id'+id).value=='' && str==1)
	{
	var req = getXMLHTTP();
	var new1;
	var allid;	
	strURL='http://www.biztradeshows.com/image_call.php?id='+id+'&math='+Math.random();
		
			if (req) {
				
				req.onreadystatechange = function() {
					if (req.readyState == 4) {
						if (req.status == 200) {

							new1=req.responseText.split(",");

							document.getElementById('allproducts_id'+id).value=req.responseText;
							document.getElementById('contain_id'+id).value=new1[0];
							document.getElementById('imagediv').innerHTML='<img src="'+new1[0]+'" onload="loadimg()" id="bigimg">';
						} else {
							alert("There was a problem while using XMLHTTP:\n" + req.statusText);
						}
					}				
				}			
				req.open("GET", strURL, true);
				req.send(null);
			}
	
	}

}
document.getElementById('loadimg').className="don";
document.getElementById('imagediv').className="doff";
imgid = id;
var allid = document.getElementById('allproducts_id'+id).value;
var idarray = allid.split(",");
var array_length = eval(document.getElementById('image'+id).value);
var k = '';
k=str;
var pic = idarray[str-1];
productName =document.getElementById('name'+id).value;
	productName = unescape(productName);
	if(productName.length > 60)
        {
		var c = productName.substring(0,60);
		c = c + "...";
		productName = c;
        }
var path=pic;
document.getElementById('imagediv').innerHTML='<img src="'+path+'" onload="loadimg()" id="bigimg">'; 
document.getElementById('prname').innerHTML="Photos of "+productName;
if(k < array_length)
{
var l = k+1;
var l1=k+1
var h = id;
document.getElementById('next').innerHTML='<A HREF="javascript:imageset('+h+','+l1+'); blowup_show()" TITLE="Use -> arrow key to view next Image"><U>Next</U> <IMG src="http://gifbt.com/gifs/next-icon.gif" ALIGN="ABSMIDDLE" WIDTH="31" HEIGHT="31"></A>';
}
else
{
document.getElementById('next').innerHTML='';
}
if(str > 1)
{
var l = k-1;
var l1=k-1
var h =id;
document.getElementById('pre').innerHTML='<A HREF="javascript:imageset('+h+','+l1+'); blowup_show()" TITLE="Use <- arrow key to view previous Image"><IMG src="http://gifbt.com/gifs/previous-icon.gif" ALIGN="ABSMIDDLE" WIDTH="31" HEIGHT="31"> <U>Previous</U></A>';
}
else
{
document.getElementById('pre').innerHTML='';
}
	var cur_pro = k;
	document.getElementById('view').innerHTML='You are Viewing <B>'+cur_pro+'</B> of <B>'+array_length+' Images</B>';
}

function videoset(id)
{
document.getElementById('view').innerHTML="";
document.getElementById('next').innerHTML="";
document.getElementById('video').innerHTML='<DIV ID="loadimg"></DIV><DIV ID="imagediv"></DIV>'+document.getElementById('videoset'+id).value; 
document.getElementById('prname').innerHTML="Video of "+document.getElementById('name'+id).value;



}


function nextimg()
{
	if(imgid < dataref.length) { imgid++; } if(imgid < dataref.length) { var newImg = imgid; document.getElementById('next').style.display='block'; document.getElementById('pre').style.display='block';	} else { var newImg = imgid; document.getElementById('next').style.display='none'; document.getElementById('pre').style.display='block'; } set_big_img_path(newImg); if (document.getElementById(newImg)) { var pic = document.getElementById(newImg); productName =pic.alt; productName = unescape(productName); if(productName.length > 40) { var c = productName.substring(0,40); c = c + "..."; productName = c; } document.getElementById('imagediv').innerHTML='<img src="'+path+'" onload="loadimg()">'; 
document.getElementById('qry').href=queryrfq;
document.getElementById('prname').innerHTML=document.getElementById('name'+id).value;
	}
	else { var newImg = --imgid; }
}
function previousimg()
{
if (imgid  > 1)
{
imgid--;
}
if (imgid <= 1) { var newImg = imgid; document.getElementById('pre').style.display='none'; document.getElementById('next').style.display='block'; } else { var newImg = imgid; document.getElementById('pre').style.display='block'; document.getElementById('next').style.display='block';	} set_big_img_path(newImg); var pic = document.getElementById(newImg); productName = pic.alt; productName = unescape(productName); if(productName.length > 40) { var c = productName.substring(0,40); c = c + "..."; productName = c; }
	document.getElementById('imagediv').innerHTML='<img src="'+path+'" onload="loadimg()">';
	document.getElementById('qry').href=queryrfq;
	document.getElementById('prname').innerHTML=document.getElementById('name'+id).value;
}
function keyDown(e) {var n = (window.Event) ? e.which : e.keyCode; if(n==9 && document.getElementById('message2').className=="don") { return false; } else if(n==32 && document.getElementById('message2').className=="don") { return false; } else if(n==27 && document.getElementById('message2').className=="don") { blowup_off(); } if((n==37 && document.getElementById('message2').className=="don") || (n==38 && document.getElementById('message2').className=="don")) { if (imgid == 1) { return false; } previousimg(); } else if((n==39 && document.getElementById('message2').className=="don") || (n==40 && document.getElementById('message2').className=="don")) { if (imgid == dataref.length) { return false; } nextimg(); return false; } } function loadimg() { 


document.getElementById('loadimg').className="doff"; 


document.getElementById('imagediv').className="don"; }
function chrom()
{
if( typeof( window.innerWidth ) == 'number' ) {
myWidth = window.innerWidth;
myHeight = window.innerHeight;
} else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    myWidth = document.documentElement.clientWidth;
    myHeight = document.documentElement.clientHeight;
  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
   myWidth = document.body.clientWidth;
   myHeight = document.body.clientHeight;
  }
var nAgt = navigator.userAgent;
var patt = /Chrome/;
}
function addEvent( obj, type, fn ){ 
   if (obj.addEventListener){ 
	  obj.addEventListener( type, fn, false );
   }
   else if (obj.attachEvent){ 
	  obj["e"+type+fn] = fn; 
	  obj[type+fn] = function(){ obj["e"+type+fn]( window.event ); } 
	  obj.attachEvent( "on"+type, obj[type+fn] ); 
   } 

}addEvent(window, 'load', chrom);
addEvent(window, 'resize', chrom);








