function newWindow( file )
{
	window.open( file,'',"status=no");

}//end func
//	script for opening product real size image in new auto sized window	

	// Set the horizontal and vertical position for the popup
	PositionX = 100;
	PositionY = 100;
	
	// Set these value approximately 20 pixels greater than the
	// size of the largest image to be used (needed for Netscape)
	
	defaultWidth  = 500;
	defaultHeight = 500;
	
	// Set autoclose true to have the window close automatically
	// Set autoclose false to allow multiple popup windows
	
	var AutoClose = true;
	
	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=200,height=200,left='+PositionX+',top='+PositionY;
	optIE='scrollbars=no,width='+(defaultWidth)+',height='+(defaultHeight)+',left='+PositionX+',top='+PositionY;
	
	function popImage(imageURL,imageTitle)
	{
		if (isNN){imgWin=window.open('about:blank','',optNN);}
		if (isIE){imgWin=window.open('about:blank','',optIE);}
		with (imgWin.document)
		{
			writeln('<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">');
			writeln('<html>\n<head>\n<title>Loading...<\/title>\n<style type="text/css">\n\t body { margin:0px; } \n<\/style>');
			writeln('<script type="text/javascript">');
			writeln('var isNN,isIE;');
			writeln('if (parseInt(navigator.appVersion.charAt(0)) >= 4)\n{');
			writeln('\t isNN = ( navigator.appName == "Netscape" ) ? 1 : 0;');
			writeln('\t isIE = ( navigator.appName.indexOf( "Microsoft" )!= -1 ) ? 1 : 0;\n}');
			writeln('function reSizeToImage(){');
			writeln('if (isIE)\n{');
			writeln('\t window.resizeTo(100,100);');
			writeln('\t width = document.images[0].width;');
			writeln('\t height = document.images[0].height + 32;');
			writeln('\t window.resizeTo(width,height);}');
			writeln('if (isNN)\n{');       
			writeln('\t window.innerWidth=document.images["preview"].width;');
			writeln('\t window.innerHeight=document.images["preview"].height;}\n}\/\/end if');
			writeln('function doTitle(){document.title="'+imageTitle+'";}');
			writeln('<\/script>');
			if (!AutoClose) writeln('<\/head>\n<body bgcolor=000000 style="scroll: no" onload="reSizeToImage();doTitle();self.focus()">')
			else writeln('<\/head>\n<body bgcolor="#000000" style="scroll: no" onload="reSizeToImage(); doTitle(); self.focus()" onblur="self.close()">');
			writeln('\t<img name="preview" src='+imageURL+' style="display: block;" alt="" \/>\n<\/body>\n<\/html>');
			close();		
		}//end with
	}
	
	
//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*//		
//functions for gallery slideshow in view_news.php
//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*//	
	function returnimgcode(theimg)
	{
		var imghtml = "";
		if (theimg[1] != ""){
			imghtml='<a href="javascript:void(0);" onclick="'+theimg[1]+'" >';
		}
		
		imghtml+='<img src="'+theimg[0]+'" alt="" />';
		
		if (theimg[1] != ""){
			imghtml+='<\/a>';
		}
			
		return imghtml;
	}
	
	/**
	* replace image in div id='loadarea' with the image from 
	* dynimages[] with index 'imgindex' and loading image title/description
	* in div id='imgtitlearea'
	*
	*/
	function modifyimage(loadarea, imgindex, imgtitlearea)
	{
		if (document.getElementById)
		{
			var imgobj=document.getElementById(loadarea);
			var titleobj=document.getElementById(imgtitlearea);
			
			imgobj.innerHTML=returnimgcode(dynimages[imgindex]);
			titleobj.innerHTML=dynimages[imgindex][2];
			
			curent_dynimages_index = imgindex;
				
			return false;
		}
	}
	
	function prevImage(loadarea, current_img_index ,imgtitlearea)
	{
		var imgindex;
		if(current_img_index == 0)
		{
			imgindex = dynimages.length - 1;
		}
		else imgindex = current_img_index -1 ;
		
		modifyimage(loadarea, imgindex ,imgtitlearea);
	}
	
	function nextImage(loadarea, current_img_index ,imgtitlearea)
	{
		var imgindex;
		if(current_img_index == (dynimages.length - 1))
		{
			imgindex = 0;
		}
		else imgindex = current_img_index + 1;
		
		modifyimage(loadarea, imgindex ,imgtitlearea);
	}
//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*//		
// END functions for gallery slideshow in view_news.php
//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*//
	
	