function clearText(thefield) {
  if (thefield.defaultValue==thefield.value) { thefield.value = "" }
} 
function replaceText(thefield) {
  if (thefield.value=="") { thefield.value = thefield.defaultValue }
}

function formrule(field)
{
	if (field.defaultValue == field.value) field.value = "";
}

function formrule2(field) {
  if (field.value == "") {
    field.value = field.defaultValue;
  }
}

function bookmark()
{
bookmarkurl="http://www.onlinelawyersource.com"
bookmarktitle="Online Lawyer Source"
if (document.all)
window.external.AddFavorite(bookmarkurl,bookmarktitle)
}

function printWindow(){
browserVersion = parseInt(navigator.appVersion)
if (browserVersion >= 4) window.print()
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}


function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function checkCriteria()
	{
		if(searchForm.ZipCode.value==' Zip Code'&&searchForm.State.selectedIndex==0)
		{
			alert('Please enter in a zipcode, state, or state and city.');
			return false;
		}		
	}
	
function getURL()
	{
		if(searchForm.theSection.selectedIndex==0)
		{
			alert('Please select an area.');
			searchForm.theSection.focus();
			return false;
		}
		if(searchForm.ZipCode.value==' Zip Code'&&searchForm.State.selectedIndex==0)
		{
			alert('Please enter in a zipcode, state, or state and city.');
			return false;
		}
		searchForm.action = 'http://w1.adhost.com/onlinelawyersource/'+searchForm.theSection.options[searchForm.theSection.selectedIndex].value+'/contact.html';
	}

function gotoURL(first, second)
{
	var start='http://www.onlinelawyersource.com/';
	window.location.href=start+first+second;
}