// Called by this reference: <script type="text/javascript" src="http://common.funeralnet.com/js/google-toolbar-fix.js"></script>
// Script source and additional details: http://code.jenseng.com/google/

if (window.attachEvent) window.attachEvent("onload",setListeners);

function setListeners() {
	inputList = document.getElementsByTagName("input");
	for (i=0; i < inputList.length; i++) {
		inputList[i].attachEvent("onpropertychange",restoreStyles);
		inputList[i].style.backgroundColor = "";
	}
	selectList = document.getElementsByTagName("select");
	for (i=0; i < selectList.length; i++) {
		selectList[i].attachEvent("onpropertychange",restoreStyles);
		selectList[i].style.backgroundColor = "";
	}
}

function restoreStyles() {
	if (event.srcElement.style.backgroundColor != "" && event.srcElement.style.backgroundColor != "#a0d0ff") {
		event.srcElement.style.backgroundColor = "#ffffff";
	}	
/*	if (event.srcElement.style.borderStyle != "") {
		event.srcElement.style.borderStyle = "solid";
	}
	if (event.srcElement.style.borderColor != "") {
		event.srcElement.style.borderColor = "#7F9DB9";
	} 
	document.all['googleblurb'].style.display = "block";
*/
}

/* 
If desired, this snippet can be placed directly above the form HTML to remind AutoFill users that they can still use this feature - not really necessary, though, I've generally concluded ... BDE, 2008.01.22
<div id="googleblurb" style="display:none;">
<p>You can use the AutoFill function on the Google toolbar to fill out the highlighted fields on this form. <a href="http://toolbar.google.com/autofill_help.html" title="AutoFill Help Page">Learn more</a>.</p>
</div>
*/