A good approach to use with this kind of situation (where the user connection/browser/etc can't be assumed) is to implement all functionality so that it can work without JS, and then hijack the form on page load and convert it to AJAX.

Another thread on this list brought up a very elegant way to handle this kind of situation. jQuery sets a special variable in the request header of its AJAX requests. The server script checks for that variable and returns different output based on that.

Blair

On 10/12/06, Michael Retrum <[EMAIL PROTECTED]> wrote:
Hey guys,
I'm having some issues with a commenting module built using jQuery
ajaxForm().  The commenting module simply takes the data from a textarea
in a form and submits it to a Php processing script for behind the
scenes processing.  Most of the time, (95%) the system performs as
intended but every once in awhile a user reports issues with being sent
to a blank page upon pressing the submit button to the form.  It appears
that people on slower connections are sometimes being sent to the Php
processing script defined in the <form action="" attribute which
in turn reveals the blank foo.php page with no action performed.
Essentially, the form is acting normally and being physically sent to
foo.php instead of performing the intended behind the scenes AJAX behavior.

Any ideas on why this is happening and how to correct it, I'm pretty
stumped, Thanks!

-Mike

_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

Reply via email to