Fixes AJAX code for form.