		
	function WindowOpen(sFileName, sWindowName) {
		var winid;
		winid = window.open(sFileName,sWindowName,'toolbar=no,width=800,height=500,directories=no,status=no,scrollbars=yes,menubar=no,resizable=yes')
	}

	function ConvertCharacters(strDoc, strConvertFrom, strConvertTo){
		var k, pos, strTemp;
		k=0;
		strDoc= "" + strDoc;
		strTemp= strDoc;
		k = strDoc.indexOf(strConvertFrom);
		while ((k < strDoc.length) && (k != -1)) {
			strTemp = strDoc.substring (0,k) + strConvertTo + strDoc.substring (parseInt(k) + parseInt(strConvertFrom.length), strDoc.length);
			if (k==strDoc.length - strConvertFrom.length){
				strDoc=strTemp;
				break;	
				}		
			else	
				pos=k + strConvertTo.length;

			strDoc=strTemp;
			k=strDoc.indexOf(strConvertFrom, pos);
		}
		strDoc=strTemp;
		return strDoc;
	}
	

	
	<!--
	var debug = true;
	function fn_right(e) {
	//alert("asdf");
	  if (navigator.appName == 'Netscape' && (e.which == 3 || e.which == 2)){
		//alert(e.which);
	  }
	  else if (navigator.appName == 'Microsoft Internet Explorer' && (event.button == 2 || event.button == 3)) {
		//alert('you just right clicked...');
		if (document.getSelection) txt = document.getSelection();
		else if (document.selection) txt = document.selection.createRange().text;
		else return;
		if(txt != ''){
			if(confirm('Search AllBookstores.com for resources related to "' + txt + '"?')){
				// get rid of leading and trailing spaces
				txt = txt.replace(/^\s*(\b.*\b|)\s*$/, "$1");

				// convert all remaining spaces to plus signs
				txt = ConvertCharacters(txt, " ", "+");
				WindowOpen('http://www.allbookstores.com/search?type=any&q=' + txt,'');
			}
		}
	  }
	  else{
		//alert("3");
	  }
	}
	document.onmousedown=fn_right;
	if (document.layers) window.captureEvents(Event.MOUSEDOWN);
	window.onmousedown=fn_right;
	//-->
	


