//Search Script, revised 04-07-08, James Payne

var TRange=null

function findString (str) {
	if (parseInt(navigator.appVersion)<4) return;
	var strFound;
	
	
	if (navigator.appName=="Netscape") {
	// NAVIGATOR-SPECIFIC CODE
		strFound=self.find(str);
		if (!strFound) {
			strFound=self.find(str,0,1)
			while (self.find(str,0,1)) continue
		}
	}

	if (navigator.appName.indexOf("Microsoft")!=-1) {
		// EXPLORER-SPECIFIC CODE
		if (TRange!=null) {
			TRange.collapse(false)
			strFound=TRange.findText(str)
			if (strFound) TRange.select()
		}
		
		if (TRange==null || strFound==0) {
			TRange=self.document.body.createTextRange()
			// Limit the text search to a contents of a div tag with the ID="content"
			TRange.moveToElementText(document.getElementById("content"));
			strFound=TRange.findText(str)
			if (strFound) TRange.select()
		}
	}
	
	if (!strFound) alert ("String '"+str+"' not found!")
}