$(document).ready(function(){
    
    $('#postcode_field').val('Enter your postcode');
	
	$('#postcode_field').focus(function() {
	    $(this).css('font-weight', 'bold').css('text-transform', 'uppercase');
		 if (this.value == this.defaultValue) {  
            this.value = '';
		 }
		 if(this.value != this.defaultValue) {
            this.select();
		 }
	});
	
	$('#postcode_field').blur(function() {
		 if ($.trim(this.value) == ''){
         this.value = (this.defaultValue ? this.defaultValue : '');
         $(this).css('font-weight', 'normal').css('text-transform', 'none');
		 }
	});
	  
//	$("#postcode-form button").click(function() {
//		var postcode = $("input#postcode_search").val();
//		if (postcode != 'Enter your postcode here!') {
//		    var google_url = "http://www.google.com/maps?saddr=" + postcode + "&daddr=SL14DX";
//		    window.open(google_url);
//		}
//		return false;
//	});
	
});
