// JavaScript Document
<!-- hide me from older browsers
// functions should use the onchange method to check individual fields for presence of
// things like "http" or "www" in the comment fields 
//
// string_to_find could be http href etc.
// string_to_scan is the comment or text field to test
//  spam_checker checks for individual spam strings
//  spam_composite uses spam checker to run down a list of common spam fields
//
function spamchecker(string_to_find,string_to_scan)
{
	if (string_to_scan == "") 
	{
		return false;
	}
	if (string_to_find.test(string_to_scan)==true) 
		{
		    alert("Please do not place links in the comment area") ;
			return true ;
		}	else {
				return false ;
		}
}

function spamco1(eval_id)
{
var eval_field = document.getElementById(eval_id).value ;
eval_field = eval_field.toUpperCase()
var clean_field = false;
	var spam_ex = "HTTP" ;
	if (spamchecker(spam_ex,eval_field)==true) 
	{
		document.getElementById(eval_id).value = "" ;
		return false ;
	}	
	var spam_ex = "WWW" ;
	if (spamchecker(spam_ex,eval_field)==true) 
	{
		document.getElementById(eval_id).value = "" ;
		return false ;
	}	
	var spam_ex = "HREF" ;
	if (spamchecker(spam_ex,eval_field)==true) 
	{
		document.getElementById(eval_id).value = "" ;
        window.location = "farm_journal.htm" 
 		return false ;
	}	
	var spam_ex = "@" ;
	if (spamchecker(spam_ex,eval_field)==true) 
	{
		document.getElementById(eval_id).value = "" ;
        window.location = "farm_journal.htm" 
 		return false ;
	}	
}		


function upperCase(x)
{
var y=document.getElementById(x).value
document.getElementById(x).value=y.toUpperCase()
}



<!-- hide me from older browsers
// functions should use the onchange method to check individual fields for presence of
// things like "http" or "www" in the comment fields 
//
// string_to_find could be http href etc.
// string_to_scan is the comment or text field to test
//  spam_checker checks for individual spam strings
//  spam_composite uses spam checker to run down a list of common spam fields
//
function spamchecker(string_to_find, string_to_scan)
{
	reg_find= new RegExp(string_to_find)
	
	if (string_to_scan == "") 
	{
		return false;
	}
	if (reg_find.test(string_to_scan) == true) 
		{
		    alert("Please do not place links in the comment area") ;
			return true ;
		}	else {
				return false ;
		}
}


