jQuery cleaner form submit function What's a better and more elegant way of writing this:

$('#footer form').submit(function(event) {
    event.preventDefault(event);
    $('#footer form .preload').spin(opts);
    $.post('contact.php', $(this).serialize(), function(response) {
        $('#footer form .preload div').remove();
        $('#footer form h5').remove();
        $('#footer form .error').html('');
        if (response == 1) {
            $('#footer form h3').after('&lt;h5&gt;Your message has been sent!&lt;/h5&gt;');
            $('#footer form input[type=submit]').fadeOut();
        } else if (response == 0) {
            $('#footer form h3').after('&lt;h5&gt;A problem occured. Please try again later.&lt;/h5&gt;');
            $('#footer form input[type=submit]').fadeOut();
        } else {
            var errors = $.parseJSON(response);
            $('label[for=name] .error').html(errors.name);
            $('label[for=email] .error').html(errors.email);
            $('label[for=message] .error').html(errors.message);
        }
    });
});
First thing I would do is cache some selectors, like the form:

$form = $('#footer form');


And then you can use it like:

$form.find('h3');