PositionX = 100;
PositionY = 100;
defaultWidth  = 500;
defaultHeight = 500;
var AutoClose = false;
if (parseInt(navigator.appVersion.charAt(0))>=4){
var isNN=(navigator.appName=="Netscape")?1:0;
var isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}
var optNN='scrollbars=no,width='+defaultWidth+',height='+defaultHeight+',left='+PositionX+',top='+PositionY;
var optIE='scrollbars=no,width=150,height=100,left='+PositionX+',top='+PositionY;
function popImage(imageURL,imageTitle){
	imageTitle = imageTitle.replace( /\"/g, "in." ); 
	if (isNN){imgWin=window.open('about:blank','',optNN);}
	if (isIE){imgWin=window.open('about:blank','',optIE);}
	with (imgWin.document){
	writeln('<html><head><title>Loading...</title><style>body{margin:0px;}</style>');writeln('<sc'+'ript>');
	writeln('var isNN,isIE;');writeln('if (parseInt(navigator.appVersion.charAt(0))>=4){');
	writeln('isNN=(navigator.appName=="Netscape")?1:0;');writeln('isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}');
	writeln('function reSizeToImage(){');writeln('if (isIE){');writeln('window.resizeTo(300,300);');
	writeln('width=300-(document.body.clientWidth-document.images[0].width);');
	writeln('height=300-(document.body.clientHeight-document.images[0].height);');
	writeln('window.resizeTo(width,height);}');writeln('if (isNN){');       
	writeln('window.innerWidth=document.images["George"].width;');writeln('window.innerHeight=document.images["George"].height;}}');
	writeln('function doTitle(){document.title="'+imageTitle+'";}');writeln('</sc'+'ript>');
	if (!AutoClose) writeln('</head><body bgcolor=000000 scroll="no" onload="reSizeToImage();doTitle();self.focus()" onclick="self.close()">')
	else writeln('</head><body bgcolor=000000 scroll="no" onload="reSizeToImage();doTitle();self.focus()" onblur="self.close()">');
	writeln('<img name="George" src='+imageURL+' style="display:block"></body></html>');
	close();		
}}

// Cool Pop up
var width,height;
var image,ext;
var cond1,cond2;
function popview(image,width,height,title) {
	var scroll;
	
	if (width==0) {
			cond1="width=554";//+16
			width="100%";
		}
		else cond1="width="+(width+16)+"";
	if (height==0) {
			cond2="height=311";//+24
			scroll="yes";
			height="100%";
			}
		else {cond2="height="+(height+24)+"";
			  scroll="no";};

	var s1 ="<TITLE>"+title+"</TITLE>";
	var s15="";
	var s2 ="<CENTER><IMG SRC="+image+" BORDER=0 HEIGHT='"+height+"' WIDTH='"+width+"' onClick='self.close()' title='"+title+"'>";
	var s3 =""//"<FORM><INPUT TYPE='BUTTON' VALUE='Close Window'"+ " onClick='self.close()' style='BACKGROUND-COLOR: #3d5999; COLOR: #ffffcf; FONT-SIZE: 9px; FONT-WEIGHT: bold; HEIGHT: 21px; WIDTH: 110px'></FORM>";
	var s4 ="</CENTER></BODY>";

	ImageWindow=window.open("", "newwin","toolbar=no,scrollbars="+scroll+",menubar=no,"+cond1+","+cond2);
	ImageWindow.document.write(s1+s15+s2+s3+s4);
	ImageWindow.document.close();
}

function activateTab(tabID) {
	var tab = document.getElementById('InfoTab' + tabID);
	var details = document.getElementById('InfoDetails' + tabID);
	currentTab.className = "infotabinactive";
	tab.className = "infotabactive";
	currentDetails.className = "detailshidden";
	details.className = "detailsshow";
	currentTab = tab;
	currentDetails = details;
}
function bookmark() {
	var title = '123Vaporizers.com'
	var url = 'http://www.123Vaporizers.com'
	if (window.sidebar) { // Mozilla Firefox Bookmark
		window.sidebar.addPanel(title, url,"");
	}
	else if (window.external) { // IE Favorite
		window.external.AddFavorite(url, title);
	}
	else if (navigator.appName == 'Netscape') {
		alert('Press Ctrl-D after closing this message to bookmark 123Vaporizers.com');
	}
}

var mirSRCAry=new Array();
var mirImgAry=new Array();
var mirWAry=new Array();
var mirHAry=new Array();
var mirImgs;

function mirImageCheck(mir){
 mirSRCAry=new Array();
 mirImgAry=new Array();
 mirWAry=new Array();
 mirHAry=new Array();
 mirImgs=document.getElementById(mir).getElementsByTagName('IMG');
 for (mir0=0;mir0<mirImgs.length;mir0++){
  mirImgAry[mir0]=mirImgs[mir0].src+'';
  if (mirImgAry[mir0].search(/yhst-/)<1){
   mirImgs[mir0].width='0';
  } else {
   mirImgs[mir0].width='50';
  }
 }
}
