Hi,

I'm very new to both AJAX and jQuery, so bare with me.

I have a form with three fields that is stored as a template (call it
myForm.php). When the parent page is loaded, it loads myForm.php
inside it and there is an AJAX script using jQuery which sends the
form data to a PHP script (call it validation.php) where the data is
validated. If there is a failure on one of the elements, the
validation.php passes back myForm.php with the error message filled in
as well as the entered values. If the validation was successful,
validation.php would pass back the template for the next step in the
form.

The problem I am running into is that on a failure, the myForm.php
with the error message and fields filled in is passed back, but
clicking on the Submit button no longer seems to call the jQuery event
handler for the click. Nothing happens. Can dynamically loaded HTML be
used in conjunction with the jQuery/AJAX on the page?

If instead of a fix, you have any better ideas as to how to accomplish
what I'm doing, feel free to let me know that as well. I don't have to
do it this way, I just want to have server side validation.

Thanks.

Adam

Reply via email to