<!-- //Hide from Browsers that don't support JavaScript

var type = "IE";	//Variable used to hold the browser name
var agt=navigator.userAgent.toLowerCase();
BrowserSniffer();

var d, dom, ie, ie4, ie5x, moz, mac, win, lin, old, ie5mac, ie5xwin, op;

d = document;
n = navigator;
na = n.appVersion;
nua = n.userAgent;
win = ( na.indexOf( 'Win' ) != -1 );
mac = ( na.indexOf( 'Mac' ) != -1 );
lin = ( nua.indexOf( 'Linux' ) != -1 );

if ( !d.layers ){
	dom = ( d.getElementById );
	op = ( nua.indexOf( 'Opera' ) != -1 );
	konq = ( nua.indexOf( 'Konqueror' ) != -1 );
	saf = ( nua.indexOf( 'Safari' ) != -1 );
	moz = ( nua.indexOf( 'Gecko' ) != -1 && !saf && !konq);
	ie = ( d.all && !op );
	ie4 = ( ie && !dom );

	/*
	ie5x tests only for functionality. ( dom||ie5x ) would be default settings. 
	Opera will register true in this test if set to identify as IE 5
	*/

	ie5x = ( d.all && dom );
	ie5mac = ( mac && ie5x );
	ie5xwin = ( win && ie5x );
}

//detects the capabilities of the browser
function BrowserSniffer() {
	if (navigator.userAgent.indexOf("Opera")!=-1 && document.getElementById) type="OP";		//Opera
	else if (document.all) type="IE";														//Internet Explorer e.g. IE4 upwards
	else if (document.layers) type="NN";													//Netscape Communicator 4
	else if (!document.all && document.getElementById) type="MO";							//Mozila e.g. Netscape 6 upwards
	else if (agt.indexOf("safari") != -1) type="SF";							            //Safari
	else type = "IE";		//I assume it will not get here
}

function ShowLayer(id, action){
	if (type=="IE") eval("document.all." + id + ".style.display='" + action + "'");
	if (type=="NN") eval("document." + id + ".display='" + action + "'");
	if (type=="MO" || type=="OP" || type=="SF") eval("document.getElementById('" + id + "').style.display='" + action + "'");

}


function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_showHideLayers() { //v6.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

//THis function is for opening up a small popup window.
function open_window(url) {
mywin = window.open(url,"PinViewer",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=770,height=600');
}

function showAlert() { //
  var now = new Date();
  var expires = new Date(2004, 1, 19, 14, 0, 0);
  if (now < expires)  {
  	window.alert("Due to systems and equipment upgrades, we will not be designing proofs or shipping orders between February 12 - February 22nd, 2004.  Please feel free to submit your order online, and you will receive your proof on February 23rd.  Please return to our home page for more details.");
   }		
  //window.alert("Due to systems and equipment upgrades, we will not be designing proofs or shipping orders between February 12 - February 22nd, 2004.  Please feel free to submit your order online, and you will receive your proof on February 23rd.  Please return to our home page for more details. "
 } 
 
 
function checkUploadFile(file)
{

var JPG_FILE = ".JPG" ;
var JPEG_FILE = ".JPEG" ;
var JPE_FILE = ".JPE" ;
var ZIP_FILE = ".ZIP" ;
var PDF_FILE = ".PDF" ;
var TIF_FILE = ".TIF" ;

    if( file == null )
	{
		return""
	}
    
	else
	
	{
		file = file.toUpperCase(file);
		file = Trim(file);
		
		// The extension must be at the end of the string, 4 or 5 characters
		// from the end, depending. Use lastIndexOf to make sure you are
		// looking from the end of the string. Trim the string and compare:
		//file = CUtils.trim(file);

		var fileLen = file.length;
	
		if (fileLen == 0)
		{
			return "";
		}
		
		else
		{
			if (fileLen<=4)
			{
				
				alert('Incorrect file type!  File must be a .jpg, .tif, or .zip file. \nPlease use the browse button to select an appropriate file.');
			}
			
			else
			{
			
				if ( (file.lastIndexOf(JPG_FILE)  == fileLen-JPG_FILE.length) ||
					(file.lastIndexOf(JPEG_FILE) == fileLen-JPEG_FILE.length) ||
					(file.lastIndexOf(PDF_FILE) == fileLen-PDF_FILE.length) ||
					(file.lastIndexOf(JPE_FILE)  == fileLen-JPE_FILE.length)||
					(file.lastIndexOf(TIF_FILE)  == fileLen-TIF_FILE.length)||
					(file.lastIndexOf(ZIP_FILE)  == fileLen-ZIP_FILE.length)  )
				{
					return"";
				}
				else
				{	
					alert('Incorrect file type!  File must be a .jpg, .tif, or .zip file. \nPlease use the browse button to select an appropriate file.');
				}
			}
		}
	}
}

function Trim(TRIM_VALUE){
	if(TRIM_VALUE.length < 1){
		return"";
	}

	TRIM_VALUE = RTrim(TRIM_VALUE);
	TRIM_VALUE = LTrim(TRIM_VALUE);
	if(TRIM_VALUE==""){
		return "";
	}
	else{
		return TRIM_VALUE;
	}
} //End Function

function RTrim(VALUE){
	var w_space = String.fromCharCode(32);
	var v_length = VALUE.length;
	var strTemp = "";
	if(v_length < 0){
	return"";
	}
	var iTemp = v_length -1;

	while(iTemp > -1){
		if(VALUE.charAt(iTemp) == w_space){
		}
		else{
			strTemp = VALUE.substring(0,iTemp +1);
			break;
		}
		iTemp = iTemp-1;

	} //End While

	return strTemp;

} //End Function

function LTrim(VALUE){
	var w_space = String.fromCharCode(32);
	if(v_length < 1){
		return"";
	}
	var v_length = VALUE.length;
	var strTemp = "";

	var iTemp = 0;

	while(iTemp < v_length){
		if(VALUE.charAt(iTemp) == w_space){
		}
		else{
			strTemp = VALUE.substring(iTemp,v_length);
			break;
		}
		iTemp = iTemp + 1;
	} //End While
	return strTemp;
} //End Function

function setBookmark(url,str){
if(str=='')str=url;
if ((document.all)&&(!moz))window.external.AddFavorite(url,str);
else alert('Press CTRL and D to add a bookmark to:\n"'+str+'".');
} 


// End Hiding -->