// JavaScript Document
$(document).ready(function(){
	$("input[name=location]").focus(function(){
		$("input[name=location]").css("text-transform", "uppercase");
		if($("input[name=location]").val() == "Enter postcode or town") {
			$("input[name=location]").val("");
			
		}
	});
	
	$("input[name=location]").blur(function(){
		
		if($("input[name=location]").val() == "") {
			$("input[name=location]").val("Enter postcode or town");
			$("input[name=location]").css("text-transform", "none");
		}
	});
	
	
	$("input[name=location2]").focus(function(){
		$("input[name=location2]").css("text-transform", "uppercase");
		if($("input[name=location2]").val() == "Enter postcode or town") {
			$("input[name=location2]").val("");
		}
	});
	
	$("input[name=location2]").blur(function(){
		if($("input[name=location2]").val() == "") {
			$("input[name=location2]").val("Enter postcode or town");
		}
	});

});

function submitenter(myfield,e)
{
var keycode;
if (window.event) keycode = window.event.keyCode;
else if (e) keycode = e.which;
else return true;

if (keycode == 13)
   {
   document.search_postcode.submit();
   return false;
   }
else
   return true;
}
