finType = 0;
    cooArr = new Array;
    typedArr = new Array;

    function getObj(f) {
        this.oForm = f;
        this.oUppht = 0;
        this.oFont = "";
        this.oUpPrice = "0.00";
        this.oLoPrice = "0.00";
        this.oFract = 0;
        this.oDepth = 0;
        this.oMount = 0;
        this.oStud = f.stud;
        this.oTempl = 0;
        this.oColor = "";
        this.oPhrase = "";
        this.oPgTotal = "0.00";
        this.oQty = f.qty;
        this.oPattern = "0.00";
        this.oFin = "0.00";
        this.oTotal = f.pgTotal;
        this.di = document.images;
        return this, resetForm(), initmb(), doSizes(), prep(), tot_cook(), doBgCols(0);
    };



    function data() {
        var ucpr = 0, lcpr = 0, cUpfee = 0, mtfee = 0;
        var siz = oUppht;
        siz = siz < 1 ? 0 : siz;
        var dep = oDepth;
        var daColor = oColor.substr(0, 4);
        siz = oFract > 0 ? (siz = siz + 1) : siz;
        this.dStr = dArr[0][siz];
        
		ucpr = dStr[dep + 1];
		ucpr=ucpr*120/100; 
        var colorFee = /(1911|1916|1910|1924|1912|1925|1906)/.test(daColor) ? ucpr * 10 / 100 : 0;
        var mtfee = /(Plain|Choose|No Mounts)/.test(oMount) ? 0 : ucpr * 20 / 100;
        ucpr = ucpr + mtfee + colorFee;
        oUpPrice = fixP(ucpr);
		var x= testFont(oFont,oPhrase);
		if(x) oPhrase=oPhrase.toUpperCase();
        oLoPrice = (x == true)? "N/A" : fixP(ucpr * 90 / 100);
    };

	function testFont(fon,txt){
		var x=false;
		var fons = Fltr.split("~"); 
		var myfon = fon.toLowerCase().replace(/\s/g, "");
		for (k = 0; k < fons.length; k++) {
			//alert(fons[k]+'---'+myfon)
			if(fons[k] == myfon){
				x=true;
				break;
			};
		};
		return x;
	};

 function analysis() {        
	oPgTotal  = '0.00';
 	var inPut      = oPhrase;
	var outPut     = '';
	var pStart       = 0;  if (oPhrase.selectionStart) {pStart=oPhrase.selectionStart;};
	var pEnd         = 0;  if (oPhrase.selectionEnd  ) {pEnd  =oPhrase.selectionEnd;};
 	var pLen       = oPhrase.length;

 	for(var i=0; i< pLen; i++) { var x = inPut.charAt(i);
			outPut +=
 			x.match(/[A-Z]/)? updatePrice(x, 'upper_case') :
			x.match(/[0-9]/)? updatePrice(x, 'nums') :
 			x.match(/[\-\.,~']/)?  updatePrice(x, 'sm_punc') :
			x.match(/[\/&\!@#$%\(\)?<>\+\*\\]/)?  updatePrice(x, 'lg_punc') :
			x.match(/[;:="]/)?  updatePrice(x, 'colo_chars') :
 			x.match(/[a-z]/)? updatePrice(x, 'lower_case') : " ";
	};
	oPhrase = outPut;
	if (oPhrase.selectionStart)
	{
		oPhrase.selectionStart=pStart;
		oPhrase.selectionEnd=pEnd  ;
	};
};

function updatePrice(x, kind) {    

 	var subT =oPgTotal-0;
 	var upcP =oUpPrice-0;
 	var locP =oLoPrice-0;


 	oPgTotal =
 		(kind =='upper_case')? fixP(subT +upcP) :
		(kind =='nums')?  fixP(subT +upcP):
		(kind =='sm_punc')? fixP(subT +(upcP-0)/3) :
		(kind =='lg_punc')? fixP(subT +(upcP-0)) :
		(kind =='colo_chars')? fixP(subT +((upcP-0)/3)*2) :
		(kind =='lower_case' && locP == 0)?
		(x=x.toUpperCase(),fixP(subT +upcP)) : fixP(subT + locP);
	return x;        //to oPhrase.value
 };


    function filtr(x) {
        rtn = false;
        if (Fltr.length > 0) {
            var fon = oFont.toLowerCase();
            var eArr = new Array;
            eArr = Fltr.split("/");
            var eaLen = eArr.length;
            for (var i = 0; i < eaLen; i++) {
                fList = eArr[i].split("~");
                if (fList[0] == fon) {
                    if (parseFloat(fList[1]) == 0) {
                        rtn = x.match(/[0-9\/&\-\:;.,']/) ? true : false;
                    } else if (fList[1] == 1) {
                        rtn = x.match(/[\/&]/) ? true : false;
                    } else if (fList[1] == 2) {
                        rtn = x.match(/[\/]/) ? true : false;
                    } else if (fList[1] == 3) {
                        rtn = x.match(/[0-9\/]/) ? true : false;
                    } else if (fList[1] == 4) {
                        rtn = x.match(/[\/\-\:;.]/) ? true : false;
                    } else if (fList[1] == 5) {
                        rtn = x.match(/-/) ? true : false;
                    } else if (fList[1] == 6) {
                        rtn = x.match(/[\/&\-\:;.,']/) ? true : false;
                    } else if (fList[1] == 7) {
                        rtn = x.match(/[0-9]/) ? true : false;
                    } else if (fList[1] == 8) {
                        rtn = x.match(/[a-z0-9]/) ? true : false;
                    } else if (fList[1] == 9) {
                        rtn = x.match(/[a-z0-9\/&\-\:;.,']/) ? true : false;
                    } else if (fList[1] == 10) {
                        rtn = x.match(/[a-z]/) ? true : false;
                    };
                    return rtn;
                };
            };
        };
    };


    function prep() {
        closePickers()
		var Qty = parseFloat(oQty.value);
        var pt = "";
        var mnt = 0;
        oPhrase = "";
        oPattern = "0.00";
       	var ptn=0, myGt=0, sLen=0;
		for (i = 1; i < 5; i++) {
            var pObj = "line" + i, sObj = "upperheight" + i, fObj = "font" + i, dObj = "depth" + i, cObj = "color" + i, mObj = "mount" + i, tObj = "template" + i, frObj = "fraction" + i;
            if (oForm[pObj].value.replace(/\s/g, "").length > 0) {
                oForm.align.disabled = i > 1 ? false : true;
                if (i > 1 && i < 5) g_id('L' + i).style.display = "";
                if (i > 1 && i < 5) g_id("mnts" + i).style.display = "";
                if (i > 0 && i < 4) g_id("I" + i).style.display = "";
				oPhrase = oForm[pObj].value;
                oFont = oForm[fObj].value
                oDepth = oForm[dObj].selectedIndex;
                oUppht = oForm[sObj].selectedIndex;
                oFract = oForm[frObj].selectedIndex;
                oColor = oForm[cObj].value;
                oMount = oForm[mObj].value;
                oTempl = oForm[tObj].selectedIndex;
                data();
                analysis();
                oForm[pObj].value = oPhrase;
                sLen += oForm[pObj].value.replace(/\s/g, "").length;
                oForm[dObj].selectedIndex = oDepth == -1 ? 0 : oDepth;
                oForm[sObj].selectedIndex = oUppht == -1 ? 0 : oUppht;
                oForm[frObj].selectedIndex = oFract == -1 ? 0 : oFract;
                oForm[mObj].selectedIndex = mnt;
                oForm[tObj].selectedIndex = oTempl == -1 ? 0 : oTempl;
                g_id('LD' + i).innerHTML = oForm[dObj][oForm[dObj].selectedIndex].text;
                g_id('UC' + i).innerHTML = oUpPrice;
                g_id('LC' + i).innerHTML = oLoPrice != "N/A" ? oLoPrice : "N/A";
                g_id('LT' + i).innerHTML = oPgTotal;
                if (oLoPrice != "N/A" && typedArr[i] != null) {
                    oForm[pObj].value = typedArr[i];
                };
				pt = oForm[tObj].selectedIndex;
                if (pt > 0) {
                    daHeight = oForm[sObj][oForm[sObj].selectedIndex].value;
                    daLen = oForm[pObj].value.replace(/\s/g, "").length;
                    addon = 1.25;
                    ptn += addon * daLen;
                    g_id('PP'+i).innerHTML = "$" + fixP(addon * daLen);
                    oPattern = fixP(addon * daLen);
                } else {
                    g_id('PP'+i).innerHTML = "0.00";
                    oPattern = "0.00";
                };
                g_id('TP'+i).innerHTML = "$" + fixP(parseFloat(oPgTotal) + parseFloat(oPattern) + parseFloat(oFin));
                myGt += parseFloat(oPgTotal) + parseFloat(oFin);
                oForm[frObj].disabled = oForm[sObj].selectedIndex == oForm[sObj].options.length - 1 ||
                    oForm[sObj][oForm[sObj].selectedIndex].value < 1 ? (oForm[frObj].selectedIndex = 0, true) : false;
            } else {
                if (i < 4) {
                    oForm["line" + (i + 1)].value = "";
                    g_id("I" + i).style.display = "none";
				};
                if (i > 1 && i < 5) g_id('L' + i).style.display = "none";
                if (i > 1 && i < 5) g_id("mnts" + i).style.display = "none";
                typedArr[i] = null;
            };
        };
        g_id('ptn').innerHTML= oPattern =  fixP(ptn);
        g_id("bl").innerHTML = "$" + fixP(myGt + ptn);
        g_id('tLtrs').innerHTML = sLen * Qty;
        g_id('tfl').innerHTML = oPgTotal = fixP(myGt * Qty);
        g_id('pgTotal').innerHTML = fixP(parseFloat(oPgTotal) + parseFloat(oPattern));
    };



    function doAbility(lObj, x) {
        var fObj = "font" + x;
        var sObj = "upperheight" + x;
        var cObj = "color" + x;
        var dObj = "depth" + x;
        var frObj = "fraction" + x;
        if (lObj.value.replace(/\s/g, "").length == 0) {
            if (x > 1) {
                for (i = x; i < 5; i++) {
                    oForm[fObj].disabled = true;
                    oForm[sObj].disabled = true;
                    oForm[cObj].disabled = true;
                    oForm[dObj].disabled = true;
                };
            };
        } else {
            oForm[fObj].disabled = false;
            oForm[sObj].disabled = false;
            oForm[cObj].disabled = false;
            oForm[dObj].disabled = false;
        };
        oForm[frObj].disabled = oForm[sObj].selectedIndex == oForm[sObj].options.length - 1 ||
            oForm[sObj][oForm[sObj].selectedIndex].value < 1 ? (oForm[frObj].selectedIndex = 0, true) : false;
    };



// dyn Template
function dyTemp(x) {
	var mObj='mount'+x, tObj='template'+x;
	var mnt=oForm[mObj].value;
	z= (/Stud|Combination|Combo|Keyhole/.test(oForm[mObj].value))? 1 : 0;
		var daLen = pArr[z].length;
		for (var j =(oForm[tObj].options.length -1); j >0; j--) { oForm[tObj].options[j] = null; };
		for(var k=0; k< daLen; k++) {
			oForm[tObj].options[k] = new Option(pArr[z][k][0], pArr[z][k][1]);
		};
};

    function doSizes() {
        if (oUppht == -1) {
            oUppht = 0;
        };
        var daLen = dArr[0].length;
        for (k = 0; k < daLen; k++) {
            oForm.upperheight1.options[k] = new Option(dArr[0][k][0] + "\"", dArr[0][k][0]);
            oForm.upperheight2.options[k] = new Option(dArr[0][k][0] + "\"", dArr[0][k][0]);
            oForm.upperheight3.options[k] = new Option(dArr[0][k][0] + "\"", dArr[0][k][0]);
            oForm.upperheight4.options[k] = new Option(dArr[0][k][0] + "\"", dArr[0][k][0]);
        };
        oUppht = oForm.upperheight1.selectedIndex;
    };


    function doSize(x) {
        if (oUppht == -1) {
            oUppht = 0;
        };
        hObj = "upperheight" + x;
        dObj = "depth" + x;
        var oldVal = oForm[hObj][oForm[hObj].selectedIndex].text;
        var dep = oForm[dObj].selectedIndex;
        dep = dep < 1 ? 0 : dep;
        for (j = oForm[hObj].options.length - 1; j > 0; j--) {
            oForm[hObj].options[j] = null;
        };
        var daLen = dArr[0].length;
        for (k = 0; k < daLen; k++) {
            oForm[hObj].options[k] = new Option(dArr[0][k][0] + "\"", dArr[0][k][0]);
            if (dArr[0][k][0] + "\"" == oldVal) {
                oForm[hObj].selectedIndex = k;
            };
        };
    };


    function addTo() {
        prep();
        var qVal = oForm.qty.value;
		if(oForm.line1.value.replace(/\s/g, "").length == 0) return alert("No letters have been entered in Line 1!");
		for (i = 1; i < 5; i++) {
			var pObj = "line" + i, mObj = "mount" + i, cObj = "color" + i, tpObj = "template" + i;
			if (oForm[pObj].value.replace(/\s/g, "").length > 0) {
					if(/Choose/.test(oForm[mObj].value)) return alert("Please Select Mount on line "+i);
			};
		};
        var cookStr = "", lTotal = 0, ptnPr = 0, lookahead = "", cnt = 1;
        var daColor = null, daHeight = 0;
        for (i = 1; i < 5; i++) {
            cnt++;
            var pObj = "line" + i, sObj = "upperheight" + i, dObj = "depth" + i, fObj = "font" + i, tObj = "gt" + i, cObj = "color" + i, laObj = "line" + cnt;
            var mObj = "mount" + i, stObj = "stud" + i, spObj = "spacer" + i, tpObj = "template" + i, bkObj = "brick" + i, frObj = "fraction" + i,subObj = "substrate" + i;
            
			lookahead = cnt == 5 || oForm[laObj].value.length == 0 ? doChars(g_id("oImg").src) : pObj;
            
			if (oForm[pObj].value.replace(/\s/g, "").length > 0) {
                var rc = oForm[mObj].value.substr(0, 1) == "C" ? "Please select a mounting option in step 6" : "";
                if (rc) {return alert(rc); rc = "";};
                
				daColor = oForm.outdoor.checked ? oForm[cObj].value + " on " + oForm[subObj][oForm[subObj].selectedIndex].text + " Acrylic with clear coat" : oForm[cObj].value + " on " + oForm[subObj][oForm[subObj].selectedIndex].text + " Acrylic without clear coat";
               
			   // calcs total allows for price of one pattern only
				lTotal =  parseFloat(g_id('LT'+i).innerHTML);
				ptnPr = parseFloat(g_id('PP'+i).innerHTML.substr(1));
				lTotal = (lTotal * qVal)+ptnPr;

daHeight = oForm[frObj].selectedIndex > 0 ? parseFloat(oForm[sObj][oForm[sObj].selectedIndex].value) + parseFloat(oForm[frObj][oForm[frObj].selectedIndex].value) : oForm[sObj][oForm[sObj].selectedIndex].text;
                
				cookStr = "Type           ~ Laminated Metal Acrylic" +
					      "|Letters       ~ " + doChars(oForm[pObj].value) +
						  "|Font          ~ " + oForm[fObj].value +
						  "|Height        ~ " + daHeight +
						  "|Depth         ~ " + oForm[dObj][oForm[dObj].selectedIndex].text +
						  "|Color         ~ " + daColor +
						  "|Mount         ~ " + oForm[mObj].value +
						  "|Ptn           ~ " + oForm[tpObj][oForm[tpObj].selectedIndex].text +
						  "|sLen   		  ~ " + oForm[stObj][oForm[stObj].selectedIndex].text+
						  "|Spacer Length ~ " + (oForm[spObj].disabled == false ? oForm[spObj][oForm[spObj].selectedIndex].text : "") +
						  "|Mortar Gap    ~ " + oForm[bkObj].value +
						  "|Image         ~ " + lookahead +
						  "|Qty           ~ " + parseFloat(qVal) +
						  "|Price         ~ " + fixP(lTotal);
                cookStr = cookStr.replace(/\s+\~\s/g, "~");
                cookStr = cookStr.replace(/\s+\|\s/g, "|");
                cookStr = cookStr.replace(/["]/g, "#Y");
                cookStr = cookStr.replace(/[']/g, "#Z");
                toCook("item_", cookStr);
            };
        };
        location.href = "s_viewCart.htm";
    };


function showPicker(inputObj, formField, line){
	    var myObj=formField.substr(0,formField.length-1)+'_picker_div';
		g_id(myObj).linenum=line;		
		g_id(myObj).elem=formField;
		if(myObj=='font_picker_div') {
			createFontList();
			g_id(myObj).style.left = getLeftPos(inputObj) - 600 + "px";
        	g_id(myObj).style.top = getTopPos(inputObj) + inputObj.offsetHeight + 2 + "px";
		}else if(myObj=='mount_picker_div') {
			createMountList();
			g_id(myObj).style.left = getLeftPos(inputObj) -158 + "px";
        	g_id(myObj).style.top = getTopPos(inputObj) + inputObj.offsetHeight -281 + "px";
			doMounts(line);
		}else{
			createColorList();
			g_id(myObj).style.left = getLeftPos(inputObj) - 600 + "px";
			g_id(myObj).style.top = getTopPos(inputObj) + inputObj.offsetHeight + 2 + "px";
		};
		closePickers(myObj);
		g_id(myObj).style.display="block";
};


//colors
function colorSelect(color){
		var myObj=g_id('color_picker_div').elem;
		g_id(myObj).value = color.substr(1);
		g_id('color_picker_div').style.display="none";
		prep();
		if(oForm.autoupdate.checked) oForm.update.click();
};


function createColorList(){
        if(g_id('colorList').innerHTML.length>0) return;
		var lName = "label";
        var myList = '<table border="0" bgColor="#D7D2CD"><tr>';
        for (i = 0; i < metallicColorNames.length; i++) {
            var mImg = "__colors/tiles/laminated/" + metallicColorNames[i].substr(0,5) + ".jpg";
			var oImg = "__colors/tiles/swatches/laminated/" + metallicColorNames[i].substr(0,5) + ".jpg";
			lName = metallicColorNames[i];
		if(i%5 ==0) myList +='</tr><tr>';
		myList += '<td><img id="'+metallicColorNames[i]+'" src="'+mImg+'" width="120" height="120" onmouseover="getImgLabel(this.id,\''+oImg+'\',\''+metallicColorNames[i]+'\')" onclick="colorSelect(\''+metallicColorNames[i]+'\')" /></td>';
		};
        myList += '</tr></table>';
		g_id('colorList').innerHTML = myList;
};

function getImgLabel(id,Img,tag){
	g_id(id).style.cursor=(g_id(id).src.indexOf('_d.jpg')==-1)? 'pointer' : 'default';
	g_id('cSwatch').src= Img; 
	g_id('cTag').innerHTML=tag;
};


//fonts
function createFontList(){
	   if(g_id('fontlist0').innerHTML.length>0) return;
	   for (j = 0; j < fonts.length; j++) { 
			var fObj = 'fontlist'+j;
			var lName = "";
			var myList = '<table border="0" width="100%" bgColor="#ffffff">';
			for (i = 0; i < fonts[j].length; i++) {
				var fIdx =i;
				var daFon = "fontimages/smallfonts/" + fonts[j][i].replace(/\s/g, "") + ".gif";
				daFon=daFon.toLowerCase();
				lName =fonts[j][i];
				myList += '<tr><td id='+lName+' style="height:26px" onmouseover="this.style.cursor=\'pointer\'" onclick="fontSelect(\''+fonts[j][i]+'\',\''+fIdx+'\')">';
				myList += '<img src="'+daFon+'" onmouseover="this.style.borderStyle=\'solid\'; this.style.borderWidth=\'thin\'" onmouseout="this.style.border=\'none\'" ></img></td></tr>';
			};
			myList += '</table>';
			g_id(fObj).innerHTML = myList;
			myList="";
	   };
};


function fontSelect(myfont){
		var line=g_id('font_picker_div').linenum;
		var myObj=g_id('font_picker_div').elem;
		g_id(myObj).value = myfont;
        g_id('font_picker_div').style.display="none";
		prep();
		if(oForm.autoupdate.checked) oForm.update.click();
};


//mounts
mountNames = new Array('plain','tape','studboss','tapped','keyhole');
mountLabels = new Array('No Mounts','Doubleside Tape Mount','Stud Boss Mount','Flush Stud Mount','Keyhole Mount');
function createMountList(){
        if(g_id('mountList').innerHTML.length>0) return;
		var myList = '<table border="0" bgColor="#D7D2CD"><tr>';
        for (i = 0; i < mountNames.length; i++) {
            mImg = "__mounts/tiles/laminated/" + mountNames[i] + ".jpg";
			lName = mountNames[i];
		if(i==5) myList +='</tr><tr>';
		var myid="mountchoices"+i;
		myList += '<td><img id="'+myid+'" src="'+mImg+'" width="120" height="120" onmouseover="this.style.cursor=(this.src.indexOf(\'_d.jpg\')==-1)? \'pointer\' : \'default\'; showLabel(this.id,'+i+')" onclick="if(this.src.indexOf(\'_d.jpg\')==-1) mountSelect(\''+mountLabels[i]+'\')" /></td>';
		};
        myList += '</tr></table>';
		g_id('mountList').innerHTML = myList;
};

function mountSelect(mount){
		var myObj=g_id('mount_picker_div').elem;
		g_id(myObj).value = mount;
		g_id('mount_picker_div').style.display="none";
		var line=g_id('mount_picker_div').linenum;
		var stObj='stud'+line, spObj='spacer'+line, mObj='mount'+line; bkObj='brick'+line;
		oForm[stObj].disabled=(/(Stud|Spacer)/.test(oForm[mObj].value))? false : (oForm[stObj].selectedIndex=0,true); 
		oForm[spObj].disabled=(/(Stud|Projected|Spacer)/.test(oForm[mObj].value))? false : (oForm[spObj].selectedIndex=0,true); 
		oForm[bkObj].disabled=(/(Stud|Projected|Spacer)/.test(oForm[mObj].value))? false : (oForm[bkObj].selectedIndex=0,true); 
		dyTemp(line);
		prep();
};

function doMounts(line){
	var o=g_id('mountchoices1');if(!o) return;
	var sObj='upperheight'+line;
	var dObj='depth'+line;
	var mObj = 'mount'+line;
	var siz= oForm[sObj][oForm[sObj].selectedIndex].value;
	var depth= parseFloat(oForm[dObj][oForm[dObj].selectedIndex].value);
	var oldval = oForm[mObj].value;
	var nArr= new Array();
	for(var i=0;i<mountNames.length;i++){
		var myid='mountchoices'+i;
		var greyImg='__mounts/tiles/laminated/'+mountNames[i]+'_d.jpg';
		var Img='__mounts/tiles/laminated/'+mountNames[i]+'.jpg';
		if(i<2){
			//plain and tape 
			g_id(myid).src=Img;
			nArr[i]=true;
		}else if(i==2){
			//stud boss
			g_id(myid).src=(siz > 2)? (nArr[i]=true,Img) : (nArr[i]=false,greyImg);
		}else if(i==3){
			//flush stud
			g_id(myid).src=(depth > 0.25)? (nArr[i]=true,Img) : (nArr[i]=false,greyImg);
		//projected spacer
		}else if(i==4){
			g_id(myid).src=(depth > 0.25 && siz > 2)? (nArr[i]=true,Img) : (nArr[i]=false,greyImg);
		}else{
			//keyhole
			g_id(myid).src=(depth > 0.25 && siz > 5)? (nArr[i]=true,Img) : (nArr[i]=false,greyImg);
		};
		if(oldval==mountLabels[i]) var itm = i;
	};
	// try to keep users chosen mount
	oForm[mObj].value = (nArr[itm]==true)? oldval : "Choose Mount";
};




function showLabel(id,idx){
	var naTxt = (idx==2)? "Only Available on letters less than 3/8 inch thick. A flush stud with standoff spacers is done on letters over 1/4 thick" :
				(idx==3)? "Only Available on letters at least 3/8 inch thick. The stud boss is used on letters up to 1/4 inch thick" :
				(idx==4)? "Only Available on letters at least 6 inch tall and more than 3/8 in thick." : 
				"Only Available on letters at least 6 inch tall and 3/8 to 3/4 inch thick, in black, white or platinum pigmented colors, or any painted color.";
	var bImg = g_id(id).src;
	if(bImg.indexOf('_d.jpg') == -1) { 
		g_id("mountinfo").innerHTML = mount[idx];
	}else{
		g_id("mountinfo").innerHTML = naTxt;
	};
}


function loadTooltips(){
			g_id("sprytooltip1").innerHTML="<div class='content'><p>To get started, type in the letters, numbers and punctuation, exactly as you want it to read when you make your sign. For multiple line signs, there are 3 other lines that will become available. What you type is what you will get. If lower case letters typed and the size is too small or lower case is not available in the chosen font, those letters will automatically convert to upper case and should convert back again when you change the height or size to something that has availability. What you type here will display in the area below with correct real world dimensions when you leave the text box.</p></div><div class='bottom'></div>";
			g_id("sprytooltip2").innerHTML="<div class='content'><p>Select the uppercase height for the line you are working on. The fraction box will add a fractional unit to the inch box ie; 3-1/2&quot; This gives you a lot of adjustment in your finished line lengths for a set of letters. Only one size can be on one line so if you want large capitals followed by small capitals, you would have to those in an empty line. For those using all lower case, only the ascenders such as 'd I h' are the same height as the corresponding uppercase letter. Body letters such as 'a c s' will be about 2/3rds smaller.</p></div><div class='bottom'></div>";
			g_id("sprytooltip3").innerHTML="<div class='content'><p>The depth measurement is the thickness of the letter when measured front to back. The width of a letter is controlled by the font. Letter depth for sheet cut letters in metal and plastic will determine the price, along with other factors. Depths can be accentuated during installation by choosing spacer stand offs from the mounting options. These allow letters to stand away by a pre-determined length of spacer, giving the letters a shadow effect.</p></div><div class='bottom'></div>";
			g_id("sprytooltip4").innerHTML="<div class='content'><p>The color \/ finish \/ material list is a multi-part selection box allowing you to choose a material(some forms) and a color or finish to apply to the material. For instance, in cut metal letters there are tabs on the top of the selection window where you can select from Aluminum, Brass, Bronze etc; and each tab will have colors or finishes applicable to that material. Aluminum also has a window for baked enamel colors. On other order forms, only the colors applicable to the product are shown. Please be aware that all colors and finishes are representative, not actual. Although we cannot provide free color samples, our website allows you to buy a single letter as a sample. We do not have minimum order quantitys except in the case of anodized colors.</p></div><div class='bottom'></div>";
			g_id("sprytooltip5").innerHTML="<div class='content'><p>Laminated metal acrylic letters are made by laminating a thin gauge sheet of anodized aluminum to a colored acrylic substrate. The Edge color is the color of the acrylic substrate.</p></div><div class='bottom'></div>";
			g_id("sprytooltip6").innerHTML="<div class='content'><p>The font list contains a selection of the most popular fonts. In cut materials, those that have a \"DEPTH\" setting, the font does not contribute to the price. Further, the font does not have to be on this list for us to be able to cut it, which means we can cut your provided font, usually at no extra charge. On other products, such as Cast metal, formed or injection molded plastics, the font chosen will be part of the determining factor of price. Further, custom fonts cannot be done in Injection molded plastic but are available in Vacuum formed plastic and cast metal. See the menu for estimators to price custom fonts and logos. Lastly and importantly, the font chosen will control the width of a given line of text. For shorter lenghts choose a condensed type font.</p></div><div class='bottom'></div>";
			g_id("sprytooltip7").innerHTML="<div class='content'><p>Aligns the display output below either left, right or center justified. TIP: You can also indent display view text by using spaces before the text to move the line text to the right. </p></div><div class='bottom'></div>";
			g_id("sprytooltip8").innerHTML="<div class='content'><p>The backgrounds allow you to see how your chosen letter color might look against a chosen background color. This is helpful for determining the correct color letter to apply to your wall color. No backgrounds are included with actual order. We do not make finished signs. All letters are individual unless specified otherwise.</p></div><div class='bottom'></div>";
			g_id("sprytooltip10").innerHTML="<div class='content'><p>Which mounting hardware best suits your project requires an understanding of the various mounts available for different types of letters. If you are not sure what kind of mounts to get, we strongly recommend reviewing our installation page with helpful videos explaining many of the mounting methods and their uses. A link to the page can be found on the site menu.</p></div><div class='bottom'></div>";
			g_id("sprytooltip11").innerHTML="<div class='content'><p>Standard stud length is the same as no preference. The factory will decide what lengths to include based on the type of letter, its height and depth. Unless you have a specific need for a specific length, this setting can be left at standard.</p></div><div class='bottom'></div>";
			g_id("sprytooltip12").innerHTML="<div class='content'><p>Stand off is where you want your letters to stand slightly away from the mounting surface for effect. Spacers are pre cut hollow tubes the slip over studs to provide a space between the letter and wall. On Vacuum Formed and Injection Molded letters, a combination all mount replaces the sleeve type mount with adjustable pads that can provide multiple depths by screwing the pad in or out along its stud.</p></div><div class='bottom'></div>";
			g_id("sprytooltip13").innerHTML="<div class='content'><p>Stud for brick applys only to letters mounting to brick walls. To avoid you having to drill into the actual brick, the factory aligns the stud mounts in equal lines that should fall on the mortar gaps between the bricks. You need to supply the measurement of your brick. Measure a single brick vertically. Standard bricks are 2-5/8&quot but your bricks may not be standard size.</p></div><div class='bottom'></div>";
			g_id("sprytooltip14").innerHTML="<div class='content'><p>A mounting pattern is a full size drawing of the letters you order, laid out with proper spacing and alignment. A pattern is critical for stud type mounts and shows you where to drill for the studs. NOTE: Gemini products require multiple patterns for multiple sets of letters. Without it, you will not get a good result and spend much time and frustration. For other types of mounts, a full size pounce pattern with inked letters that are perforated on their outlines, allows you to rub chalk through leaving an impression on the wall.</p></div><div class='bottom'></div>";

	var sprytooltip1 = new Spry.Widget.Tooltip("sprytooltip1","#ttLetters", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip2 = new Spry.Widget.Tooltip("sprytooltip2","#ttHeight", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip3 = new Spry.Widget.Tooltip("sprytooltip3","#ttDepth", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip4 = new Spry.Widget.Tooltip("sprytooltip4","#ttColor", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip5 = new Spry.Widget.Tooltip("sprytooltip5","#ttEdgeColor", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip6 = new Spry.Widget.Tooltip("sprytooltip6","#ttFont", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip7 = new Spry.Widget.Tooltip("sprytooltip7","#ttAlign", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip8 = new Spry.Widget.Tooltip("sprytooltip8","#ttBackground", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip10 = new Spry.Widget.Tooltip("sprytooltip10","#ttMounts", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip11 = new Spry.Widget.Tooltip("sprytooltip11","#ttStud", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip12 = new Spry.Widget.Tooltip("sprytooltip12","#ttStandoff", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip13 = new Spry.Widget.Tooltip("sprytooltip13","#ttBrick", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
	var sprytooltip14 = new Spry.Widget.Tooltip("sprytooltip14","#ttPattern", {useEffect:"blind", showDelay:250, hideDelay:500, followMouse:true});
};


function zoomer(img,alt){
	$('box').innerHTML="<div id='mTxt'><img src="+img+" class=\"zoom\" onclick=\"hm(\'box\')\"/><br /><center>"+alt+"</center></div>";
	sm('box',316,330);
};


function pr(){
	var pt = "<table bgcolor=\"#666666\" ALIGN=\"center\" border=\"0\" cellspacing=\"1\" cellpadding=\"5\" class=\"table_border\"><tr><td bgcolor=\"#d7d2cd\" colspan=\"7\"><div align=\"center\"><span class=\"f\">Base Price for Metal Faced Acrylic Letters & Numbers</span></div></td></tr><tr><td bgcolor=\"#d7d2cd\"><div align=\"center\">Height</div></td><td bgcolor=\"#d7d2cd\" class=\"f\"><div align=\"center\">1/8&quot (3mm)</div></td><td bgcolor=\"#d7d2cd\" class=\"f\"><div align=\"center\">3/16&quot (4.5mm)</div></td><td bgcolor=\"#d7d2cd\" class=\"f\"><div align=\"center\">1/4&quot (6mm)</div></td><td bgcolor=\"#d7d2cd\" class=\"f\"><div align=\"center\">3/8&quot (9mm)</div></td><td bgcolor=\"#d7d2cd\" class=\"f\"><div align=\"center\">1/2&quot (12mm)</div></td></tr>";
	for (i = 0; i < dArr[0].length; i++) {
		bgCols = "ffffff";
		pt += "<tr><td bgcolor=\"#d7d2cd\" ><div align=\"center\">" + dArr[0][i][0] + "&quot</div></td>";
		pt += "<td bgcolor=\"#d7d2cd\" ><div align=\"center\">" + fixP(dArr[0][i][1]) + "</div></td>";
		pt += "<td bgcolor=\"#d7d2cd\" ><div align=\"center\">" + fixP(dArr[0][i][2]) + "</div></td>";
		pt += "<td bgcolor=\"#d7d2cd\" ><div align=\"center\">" + fixP(dArr[0][i][3]) + "</div></td>";
		pt += "<td bgcolor=\"#d7d2cd\" ><div align=\"center\">" + fixP(dArr[0][i][4]) + "</div></td>";
		pt += "<td bgcolor=\"#d7d2cd\" ><div align=\"center\">" + fixP(dArr[0][i][5]) + "</div></td>";
	};
	pt += "</tr></table>";
	document.getElementById("priceTable").innerHTML = pt;
};
