Replaces some form submits with AJAX calls.