
function clearifdefault (input,defaultval) {
	if (input.value == defaultval){
		input.value = ''
	}
}

function defaultifclear (input,defaultval) {
	if (input.value == ''){
		input.value = defaultval
	}
}

$(document).ready(function(){
	$('.learnmore').hover(
            function(){ // Change the input image's source when we "roll on"
                $(this).attr({ src : '/_img/learn-more-hover.gif'});
            },
            function(){ // Change the input image's source back to the default on "roll off"
                $(this).attr({ src : '/_img/learn-more.gif'});             }
        );
	
	$('.exploremore').hover(
            function(){ // Change the input image's source when we "roll on"
                $(this).attr({ src : '/_img/explore-the-neighborhood-hover.gif'});
            },
            function(){ // Change the input image's source back to the default on "roll off"
                $(this).attr({ src : '/_img/explore-the-neighborhood.gif'});             }
        );
        
        $('#searchsubmit').hover(
            function(){ // Change the input image's source when we "roll on"
                $(this).attr({ src : '/_img/search-go-hover.gif'});
            },
            function(){ // Change the input image's source back to the default on "roll off"
                $(this).attr({ src : '/_img/search-go.gif'});             }
        );
	
	$('.searchinput').hover(
            function(){ // Change when we "roll on"
                $(this).css({'color' : '#222222'});
            },
            function(){ // Change back to the default on "roll off"
                $(this).css({'color' : '#5d5e5a'});             }
        );
});

