function switchSearchFormBox() {
theDiv = $('#SearchFormDiv');
theButton =$('#SearchSwitchFormButton');
if(theDiv.is(':visible')) {
	theDiv.hide();
	theButton.removeClass('ButtonPressed');
} else {
	theDiv.show();
	theButton.addClass('ButtonPressed');
}

	
}


function SubmitSearch(page) {
$('#SearchPage').val(page);
TheForm = $('#searchform');
var serializedForm = TheForm.serialize();
alert(serializedForm);
('#SearchResultsBox').load('/MDG-Database/Search/Submit.html', serializedForm);
}


$("#searchform").submit(
function(){
var data = $(this).serialize();
alert(data);
$.post( "/MDG-Database/Search/Submit.html", {
data: data },
function(response){
alert(response);
return false;
}
);
return false;
}
);

