var dom = (document.getElementById) ? true : false;
var ns5 = (!document.all && dom || window.opera) ? true: false;
var ie5 = ((navigator.userAgent.indexOf("MSIE")>-1) && dom) ? true : false;
var ie4 = (document.all && !dom) ? true : false;
var nodyn = (!ns5 && !ie4 && !ie5 && !dom) ? true : false;

var origWidth, origHeight;

// avoid error of passing event object in older browsers
if (nodyn) { event = "nope" }

///////////////////////  CUSTOMIZE HERE   ////////////////////
// settings for tooltip 
// Do you want tip to move when mouse moves over link?
var tipFollowMouse= true;	
// Be sure to set tipWidth wide enough for widest image
var tipWidth= 160;
var offX= 20;	// how far from mouse to show tip
var offY= 12; 
var tipFontFamily= "Verdana, arial, helvetica, sans-serif";
var tipFontSize= "8pt";
// set default text color and background color for tooltip here
// individual tooltips can have their own (set in messages arrays)
// but don't have to
var tipFontColor= "#000000";
var tipBgColor= "#ffffff"; 
var tipBorderColor= "#c9c9c9";
var tipBorderWidth= 1;
var tipBorderStyle= "solid";
var tipPadding= 2;

// tooltip content goes here (image, description, optional bgColor, optional textcolor)
var messages = new Array();
// multi-dimensional arrays containing: 
// image and text for tooltip
// optional: bgColor and color to be sent to tooltip
messages[1] = new Array('images/products/CARD HOLDERS/544.317/911771-002.JPG','',"#FFFFFF");
messages[2] = new Array('images/products/CARD HOLDERS/544.617A/911771-003.JPG','',"#ffffff");
messages[3] = new Array('images/products/CARD HOLDERS/544.617B/911771-005.JPG','',"#ffffff");
messages[4] = new Array('images/products/CARD HOLDERS/544.634/911771-007.JPG','',"#ffffff");
messages[5] = new Array('images/products/DATA KEY/A/911771-008.JPG','',"#ffffff");
messages[6] = new Array('images/products/DATA KEY/A/911771-009.JPG','',"#ffffff");
messages[7] = new Array('images/products/DATA KEY/B/911771-010.jpg','',"#ffffff");
messages[8] = new Array('images/products/DATA KEY/B/911771-011.jpg','',"#ffffff");
messages[9] = new Array('images/products/DATA KEY/C/911771-012.JPG','',"#ffffff");
messages[10] = new Array('images/products/DATA KEY/C/911771-013.JPG','',"#ffffff");
messages[11] = new Array('images/products/DATA KEY/D/911771-014.JPG','',"#ffffff");
messages[12] = new Array('images/products/DATA KEY/D/911771-015.JPG','',"#ffffff");
messages[13] = new Array('images/products/DOG AND CAT TAG/BRANDY/911771-016.jpg','',"#ffffff");
messages[14] = new Array('images/products/DOG AND CAT TAG/MOLLY/911771-018.jpg','',"#ffffff");
messages[15] = new Array('images/products/DOG AND CAT TAG/TARZAN/911771-020.jpg','',"#ffffff");
messages[16] = new Array('images/products/KEY RINGS/A/911771-022.JPG','',"#ffffff");
messages[17] = new Array('images/products/KEY RINGS/B/911771-024.JPG','',"#ffffff");
messages[18] = new Array('images/products/KEY RINGS/B/911771-025.JPG','',"#ffffff");
messages[19] = new Array('images/products/KNIFE 544.221/BACK SIDE/911771-026.JPG','',"#ffffff");
messages[20] = new Array('images/products/KNIFE 544.221/FRONT SIDE/911771-028.JPG','',"#ffffff");
messages[21] = new Array('images/products/KNIFE 544.221/FRONT SIDE/911771-029.JPG','',"#ffffff");
messages[22] = new Array('images/products/LIGHTER/911771-031.JPG','',"#ffffff");
messages[23] = new Array('images/products/LIGHTER/911771-032.JPG','',"#ffffff");
messages[24] = new Array('images/products/MAT/911771-034.jpg','',"#ffffff");
messages[25] = new Array('images/products/MUG MATS/A/911771-038.jpg','',"#ffffff");
messages[26] = new Array('images/products/MUG MATS/A/911771-039.jpg','',"#ffffff");
messages[27] = new Array('images/products/MUG MATS/B/911771-043.JPG','',"#ffffff");
messages[28] = new Array('images/products/NAME PLAQUE/A GOLD BIG/911771-047.jpg','',"#ffffff");
messages[29] = new Array('images/products/NAME PLAQUE/A GOLD BIG/911771-048.jpg','',"#ffffff");
messages[30] = new Array('images/products/NAME PLAQUE/B GOLD SMALL/911771-050.jpg','',"#ffffff");
messages[31] = new Array('images/products/NAME PLAQUE/C SILVER/911771-052.JPG','',"#ffffff");
messages[32] = new Array('images/products/NAME PLATE 544.616_/911771-044.JPG','',"#ffffff");
messages[33] = new Array('images/products/NAME PLATE 544.616_/911771-046.JPG','',"#ffffff");
messages[34] = new Array('images/products/OPENER/911771-054.JPG','',"#ffffff");
messages[35] = new Array('images/products/OPENER/911771-056.JPG','',"#ffffff");
messages[36] = new Array('images/products/PAPER STAND/911771-057.jpg','',"#ffffff");
messages[37] = new Array('images/products/PAPER STAND/911771-058.jpg','',"#ffffff");
messages[38] = new Array('images/products/PAPER STAND/911771-060.JPG','',"#ffffff");
messages[39] = new Array('images/products/PEN/911771-062.JPG','',"#ffffff");
messages[40] = new Array('images/products/PEN/911771-063.JPG','',"#ffffff");
messages[41] = new Array('images/products/STAR/911771-065.JPG','',"#ffffff");
messages[42] = new Array('images/products/THERMOS/911771-068.JPG','',"#ffffff");
messages[43] = new Array('images/products/TOUCHES/BLACK/911771-069.JPG','',"#ffffff");
messages[44] = new Array('images/products/TOUCHES/BLUE/911771-070.JPG','',"#ffffff");
messages[45] = new Array('images/products/TOUCHES/SILVER P513.082/911771-071.jpg','',"#ffffff");
messages[46] = new Array('images/products/SECONDSET/A/911771-169.JPG','',"#ffffff");
messages[47] = new Array('images/products/SECONDSET/AtoZ/911771-073.JPG','',"#ffffff");
messages[48] = new Array('images/products/SECONDSET/B/911771-171.JPG','',"#ffffff");
messages[49] = new Array('images/products/SECONDSET/B/911771-176.JPG','',"#ffffff");
messages[50] = new Array('images/products/SECONDSET/BOX/911771-075.JPG','',"#ffffff");
messages[51] = new Array('images/products/SECONDSET/BOX/911771-077.JPG','',"#ffffff");
messages[52] = new Array('images/products/SECONDSET/C/911771-178.JPG','',"#ffffff");
messages[53] = new Array('images/products/SECONDSET/C/911771-180.JPG','',"#ffffff");
messages[54] = new Array('images/products/SECONDSET/COPPER PLATE/A/911771-080.JPG','',"#ffffff");
messages[55] = new Array('images/products/SECONDSET/COPPER PLATE/A/911771-081.JPG','',"#ffffff");
messages[56] = new Array('images/products/SECONDSET/COPPER PLATE/A/911771-082.JPG','',"#ffffff");
messages[57] = new Array('images/products/SECONDSET/COPPER PLATE/A/911771-083.JPG','',"#ffffff");
messages[58] = new Array('images/products/SECONDSET/COPPER PLATE/A/911771-084.JPG','',"#ffffff");
messages[59] = new Array('images/products/SECONDSET/COPPER PLATE/B/911771-088.JPG','',"#ffffff");
messages[60] = new Array('images/products/SECONDSET/COPPER PLATE/B/911771-089.JPG','',"#ffffff");
messages[61] = new Array('images/products/SECONDSET/COPPER PLATE/B/911771-090.JPG','',"#ffffff");
messages[62] = new Array('images/products/SECONDSET/COPPER PLATE/B/911771-091.JPG','',"#ffffff");
messages[63] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-092.JPG','',"#ffffff");
messages[64] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-093.JPG','',"#ffffff");
messages[65] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-094.JPG','',"#ffffff");
messages[66] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-095.JPG','',"#ffffff");
messages[67] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-096.JPG','',"#ffffff");
messages[68] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-097.JPG','',"#ffffff");
messages[69] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-098.JPG','',"#ffffff");
messages[70] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-099.JPG','',"#ffffff");
messages[71] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-100.JPG','',"#ffffff");
messages[72] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-101.JPG','',"#ffffff");
messages[73] = new Array('images/products/SECONDSET/COPPER PLATE/C/911771-102.JPG','',"#ffffff");
messages[74] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-105.JPG','',"#ffffff");
messages[75] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-106.JPG','',"#ffffff");
messages[76] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-107.JPG','',"#ffffff");
messages[77] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-108.JPG','',"#ffffff");
messages[78] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-109.JPG','',"#ffffff");
messages[79] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-110.JPG','',"#ffffff");
messages[80] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-111.JPG','',"#ffffff");
messages[81] = new Array('images/products/SECONDSET/COPPER PLATE/D/911771-112.JPG','',"#ffffff");
messages[82] = new Array('images/products/SECONDSET/COPPER PLATE/E/911771-114.JPG','',"#ffffff");
messages[83] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-116.JPG','',"#ffffff");
messages[84] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-117.JPG','',"#ffffff");
messages[85] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-118.JPG','',"#ffffff");
messages[86] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-119.JPG','',"#ffffff");
messages[87] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-120.JPG','',"#ffffff");
messages[88] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-121.JPG','',"#ffffff");
messages[89] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-122.JPG','',"#ffffff");
messages[90] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-123.JPG','',"#ffffff");
messages[91] = new Array('images/products/SECONDSET/COPPER PLATE/F/911771-124.JPG','',"#ffffff");
messages[92] = new Array('images/products/SECONDSET/COPPER PLATE/G/911771-127.JPG','',"#ffffff");
messages[93] = new Array('images/products/SECONDSET/COPPER PLATE/H/911771-129.JPG','',"#ffffff");
messages[94] = new Array('images/products/SECONDSET/COPPER PLATE/I/911771-132.JPG','',"#ffffff");
messages[95] = new Array('images/products/SECONDSET/CRICKET MENS TROPHY/911771-133.JPG','',"#ffffff");
messages[96] = new Array('images/products/SECONDSET/D/911771-183.JPG','',"#ffffff");
messages[97] = new Array('images/products/SECONDSET/D/911771-184.JPG','',"#ffffff");
messages[98] = new Array('images/products/SECONDSET/D/911771-185.JPG','',"#ffffff");
messages[99] = new Array('images/products/SECONDSET/LADIES PRICE LIST WOODEN/911771-135.JPG','',"#ffffff");
messages[100] = new Array('images/products/SECONDSET/MEDAL/911771-137.JPG','',"#ffffff");
messages[101] = new Array('images/products/SECONDSET/MEDAL/911771-138.JPG','',"#ffffff");
messages[102] = new Array('images/products/SECONDSET/MEDIA SOLUTIONS/911771-140.JPG','',"#ffffff");
messages[103] = new Array('images/products/SECONDSET/PENS 2/black fountain pen/911771-144.JPG','',"#ffffff");
messages[104] = new Array('images/products/SECONDSET/PENS 2/black fountain pen/911771-145.JPG','',"#ffffff");
messages[105] = new Array('images/products/SECONDSET/PENS 2/black fountain pen/911771-146.JPG','',"#ffffff");
messages[106] = new Array('images/products/SECONDSET/PENS 2/blue pen/911771-147.JPG','',"#ffffff");
messages[107] = new Array('images/products/SECONDSET/PENS 2/boxed pen/911771-149.JPG','',"#ffffff");
messages[108] = new Array('images/products/SECONDSET/PENS 2/boxed pen/911771-150.JPG','',"#ffffff");
messages[109] = new Array('images/products/SECONDSET/PENS 2/boxed pen/911771-151.JPG','',"#ffffff");
messages[110] = new Array('images/products/SECONDSET/PENS 2/boxed pen/911771-152.JPG','',"#ffffff");
messages[111] = new Array('images/products/SECONDSET/PENS 2/silver biro/911771-153.JPG','',"#ffffff");
messages[112] = new Array('images/products/SECONDSET/PENS 2/silver biro/911771-154.JPG','',"#ffffff");
messages[113] = new Array('images/products/SECONDSET/PENS 2/silver biro/911771-156.JPG','',"#ffffff");
messages[114] = new Array('images/products/SECONDSET/PENS 2/silver fountain pen/911771-157.JPG','',"#ffffff");
messages[115] = new Array('images/products/SECONDSET/PENS 2/silver fountain pen/911771-160.JPG','',"#ffffff");
messages[116] = new Array('images/products/SECONDSET/THE MAYORS CHARITY/911771-162.JPG','',"#ffffff");
messages[117] = new Array('images/products/SECONDSET/TROPHIES/FOOTBALL/911771-189.JPG','',"#ffffff");
messages[118] = new Array('images/products/SECONDSET/TROPHIES/GOLF/911771-191.JPG','',"#ffffff");
messages[119] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-197.JPG','',"#ffffff");
messages[120] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-209.JPG','',"#ffffff");
messages[121] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-193.JPG','',"#ffffff");
messages[122] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-194.JPG','',"#ffffff");
messages[123] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-195.JPG','',"#ffffff");
messages[124] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-196.JPG','',"#ffffff");
messages[125] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-198.JPG','',"#ffffff");
messages[126] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-199.JPG','',"#ffffff");
messages[127] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-200.JPG','',"#ffffff");
messages[128] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-201.JPG','',"#ffffff");
messages[129] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-202.JPG','',"#ffffff");
messages[130] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-205.JPG','',"#ffffff");
messages[131] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-206.JPG','',"#ffffff");
messages[132] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-207.JPG','',"#ffffff");
messages[133] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-208.JPG','',"#ffffff");
messages[134] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-210.JPG','',"#ffffff");
messages[135] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-203.JPG','',"#ffffff");
messages[136] = new Array('images/products/IMPROVED SMILE PRODUCT/911771-204.JPG','',"#ffffff");
messages[137] = new Array('images/products/New_product/01 STONES/A BROWN/911794-001.JPG','',"#ffffff");
messages[138] = new Array('images/products/New_product/01 STONES/A BROWN/911794-002.JPG','',"#ffffff");
messages[139] = new Array('images/products/New_product/01 STONES/A BROWN/911794-003.JPG','',"#ffffff");
messages[140] = new Array('images/products/New_product/01 STONES/A BROWN/911794-004.JPG','',"#ffffff");
messages[141] = new Array('images/products/New_product/01 STONES/B BLACK/911794-005.JPG','',"#ffffff");
messages[142] = new Array('images/products/New_product/01 STONES/B BLACK/911794-006.JPG','',"#ffffff");
messages[143] = new Array('images/products/New_product/01 STONES/B BLACK/911794-007.JPG','',"#ffffff");
messages[144] = new Array('images/products/New_product/01 STONES/B BLACK/911794-008.JPG','',"#ffffff");
messages[145] = new Array('images/products/New_product/01 STONES/C SMALL/911794-009.JPG','',"#ffffff");
messages[146] = new Array('images/products/New_product/01 STONES/C SMALL/911794-010.JPG','',"#ffffff");
messages[147] = new Array('images/products/New_product/01 STONES/C SMALL/911794-011.JPG','',"#ffffff");
messages[148] = new Array('images/products/New_product/02 BROOCHES/911794-012.JPG','',"#ffffff");
messages[149] = new Array('images/products/New_product/02 BROOCHES/911794-013.JPG','',"#ffffff");
messages[150] = new Array('images/products/New_product/02 BROOCHES/911794-014.JPG','',"#ffffff");
messages[151] = new Array('images/products/New_product/02 BROOCHES/911794-015.JPG','',"#ffffff");
messages[152] = new Array('images/products/New_product/02 BROOCHES/911794-016.JPG','',"#ffffff");
messages[153] = new Array('images/products/New_product/02 BROOCHES/911794-017.JPG','',"#ffffff");
messages[154] = new Array('images/products/New_product/03 BADGES/A/911794-018.JPG','',"#ffffff");
messages[155] = new Array('images/products/New_product/03 BADGES/A/911794-019.JPG','',"#ffffff");
messages[156] = new Array('images/products/New_product/03 BADGES/B/911794-020.JPG','',"#ffffff");
messages[157] = new Array('images/products/New_product/03 BADGES/B/911794-021.JPG','',"#ffffff");
messages[158] = new Array('images/products/New_product/03 BADGES/C/911794-022.JPG','',"#ffffff");
messages[159] = new Array('images/products/New_product/03 BADGES/C/911794-023.JPG','',"#ffffff");
messages[160] = new Array('images/products/New_product/03 BADGES/D/911794-024.JPG','',"#ffffff");
messages[161] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-025.JPG','',"#ffffff");
messages[162] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-026.JPG','',"#ffffff");
messages[163] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-027.JPG','',"#ffffff");
messages[164] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-028.JPG','',"#ffffff");
messages[165] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-029.JPG','',"#ffffff");
messages[166] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-030.JPG','',"#ffffff");
messages[167] = new Array('images/products/New_product/04 GLASSES AND BOTLE/911794-031.JPG','',"#ffffff");
messages[168] = new Array('images/products/New_product/05 KEY RING WALLET/911794-032.JPG','',"#ffffff");
messages[169] = new Array('images/products/New_product/05 KEY RING WALLET/911794-033.JPG','',"#ffffff");
messages[170] = new Array('images/products/New_product/06 BROWN WALLET/911794-034.JPG','',"#ffffff");
messages[171] = new Array('images/products/New_product/06 BROWN WALLET/911794-035.JPG','',"#ffffff");
messages[172] = new Array('images/products/New_product/07 CD WALLET/911794-036.JPG','',"#ffffff");
messages[173] = new Array('images/products/New_product/07 CD WALLET/911794-037.JPG','',"#ffffff");
messages[174] = new Array('images/products/New_product/07 CD WALLET/911794-038.JPG','',"#ffffff");
messages[175] = new Array('images/products/New_product/08 BLACK FOLDERS/A/911794-039.JPG','',"#ffffff");
messages[176] = new Array('images/products/New_product/08 BLACK FOLDERS/A/911794-040.JPG','',"#ffffff");
messages[177] = new Array('images/products/New_product/08 BLACK FOLDERS/B/911794-041.JPG','',"#ffffff");
messages[178] = new Array('images/products/New_product/08 BLACK FOLDERS/B/911794-043.JPG','',"#ffffff");
messages[179] = new Array('images/products/New_product/09 GLASS/911794-044.JPG','',"#ffffff");
messages[180] = new Array('images/products/New_product/09 GLASS/911794-045.JPG','',"#ffffff");
messages[181] = new Array('images/products/New_product/10 TROPHIES/A/911794-046.JPG','',"#ffffff");
messages[182] = new Array('images/products/New_product/10 TROPHIES/A/911794-047.JPG','',"#ffffff");
messages[183] = new Array('images/products/New_product/10 TROPHIES/B/911794-048.JPG','',"#ffffff");
messages[184] = new Array('images/products/New_product/10 TROPHIES/B/911794-049.JPG','',"#ffffff");
//messages[185] = new Array('','',"#ffffff");
//messages[186] = new Array('','',"#ffffff");
//messages[187] = new Array('','',"#ffffff");
//messages[188] = new Array('','',"#ffffff");
//messages[189] = new Array('','',"#ffffff");
//messages[190] = new Array('','',"#ffffff");



////////////////////  END OF CUSTOMIZATION AREA  ///////////////////

// preload images that are to appear in tooltip
// from arrays above
if (document.images) {
	var theImgs = new Array();
	for (var i=1; i<messages.length; i++) {
  	theImgs[i] = new Image();
		theImgs[i].src = messages[i][1];
  }
}

// to layout image and text, 2-row table, image centered in top cell
// these go in var tip in doTooltip function
// startStr goes before image, midStr goes between image and text
var startStr = '<table width="' + tipWidth + '"><tr><td align="center" width="100%"><img src="';
var midStr = '" border="0"></td></tr><tr><td valign="top">';
var endStr = '</td></tr></table>';

////////////////////////////////////////////////////////////
//  initTip	- initialization for tooltip.
//		Global variables for tooltip. 
//		Set styles
//		Set up mousemove capture if tipFollowMouse set true.
////////////////////////////////////////////////////////////
var tooltip, tipcss;
function initTip() {
	if (nodyn) return;
	tooltip = (ie4)? document.all['tipDiv']: (ie5||ns5)? document.getElementById('tipDiv'): null;
	tipcss = tooltip.style;
	if (ie4||ie5||ns5) {	// ns4 would lose all this on rewrites
		tipcss.width = tipWidth+"px";
		tipcss.fontFamily = tipFontFamily;
		tipcss.fontSize = tipFontSize;
		tipcss.color = tipFontColor;
		tipcss.backgroundColor = tipBgColor;
		tipcss.borderColor = tipBorderColor;
		tipcss.borderWidth = tipBorderWidth+"px";
		tipcss.padding = tipPadding+"px";
		tipcss.borderStyle = tipBorderStyle;
	}
	if (tooltip&&tipFollowMouse) {
		document.onmousemove = trackMouse;
	}
}

window.onload = initTip;

/////////////////////////////////////////////////
//  doTooltip function
//			Assembles content for tooltip and writes 
//			it to tipDiv
/////////////////////////////////////////////////
var t1,t2;	// for setTimeouts
var tipOn = false;	// check if over tooltip link
function doTooltip(evt,num) {
	if (!tooltip) return;
	if (t1) clearTimeout(t1);	if (t2) clearTimeout(t2);
	tipOn = true;
	// set colors if included in messages array
	if (messages[num][2])	var curBgColor = messages[num][2];
	else curBgColor = tipBgColor;
	if (messages[num][3])	var curFontColor = messages[num][3];
	else curFontColor = tipFontColor;
	if (ie4||ie5||ns5) {
		var tip = startStr + messages[num][0] + midStr + '<span style="font-family:' + tipFontFamily + '; font-size:' + tipFontSize + '; color:' + curFontColor + ';">' + messages[num][1] + '</span>' + endStr;
		tipcss.backgroundColor = curBgColor;
	 	tooltip.innerHTML = tip;
	}
	if (!tipFollowMouse) positionTip(evt);
	else t1=setTimeout("tipcss.visibility='visible'",100);
}

var mouseX, mouseY;
function trackMouse(evt) {
	standardbody=(document.compatMode=="CSS1Compat")? document.documentElement : document.body //create reference to common "body" across doctypes
	mouseX = (ns5)? evt.pageX: window.event.clientX + standardbody.scrollLeft;
	mouseY = (ns5)? evt.pageY: window.event.clientY + standardbody.scrollTop;
	if (tipOn) positionTip(evt);
}

/////////////////////////////////////////////////////////////
//  positionTip function
//		If tipFollowMouse set false, so trackMouse function
//		not being used, get position of mouseover event.
//		Calculations use mouseover event position, 
//		offset amounts and tooltip width to position
//		tooltip within window.
/////////////////////////////////////////////////////////////
function positionTip(evt) {
	if (!tipFollowMouse) {
		mouseX = (ns5)? evt.pageX: window.event.clientX + standardbody.scrollLeft;
		mouseY = (ns5)? evt.pageY: window.event.clientY + standardbody.scrollTop;
	}
	// tooltip width and height
	var tpWd = (ie4||ie5)? tooltip.clientWidth: tooltip.offsetWidth;
	var tpHt = (ie4||ie5)? tooltip.clientHeight: tooltip.offsetHeight;
	// document area in view (subtract scrollbar width for ns)
	var winWd = (ns5)? window.innerWidth-20+window.pageXOffset: standardbody.clientWidth+standardbody.scrollLeft;
	var winHt = (ns5)? window.innerHeight-20+window.pageYOffset: standardbody.clientHeight+standardbody.scrollTop;
	// check mouse position against tip and window dimensions
	// and position the tooltip 
	if ((mouseX+offX+tpWd)>winWd) 
		tipcss.left = mouseX-(tpWd+offX)+"px";
	else tipcss.left = mouseX+offX+"px";
	if ((mouseY+offY+tpHt)>winHt) 
		tipcss.top = winHt-(tpHt+offY)+"px";
	else tipcss.top = mouseY+offY+"px";
	if (!tipFollowMouse) t1=setTimeout("tipcss.visibility='visible'",100);
}

function hideTip() {
	if (!tooltip) return;
	t2=setTimeout("tipcss.visibility='hidden'",100);
	tipOn = false;
}

document.write('<div id="tipDiv" style="position:absolute; visibility:hidden; z-index:100"></div>')
