I'm using the latest version of the form plugin from 
http://jquery.malsup.com/form/
and am having problems with a form that has an input of type "file".

I have read all the info about how to return JSON and such, how an
iframe is used, etc.  I've Googled around and searched this list, but
m not seeing anything relating to my problem.

I have a series of forms which pop up in a modal dialog and are
submitted view the ajaxSubmit method.  Only one of these forms has a
file field in it, and it does not work at all.  Upon hitting submit, I
see no network activity in the Firebug console, though I didn't really
expect any given that this uses the iframe.   However, the Net panel
of Firebug shows no activity either.  Further, the PHP file at which
this form is pointed has a LOT of debug statements in it, and none of
them show up in the logs when I it submit.

I added some debugging to the ajax-on-error method I'd set for this
call by adding a console.log() of the error text and the error object
which are passed to the error function and they say

"error"

and

"SyntaxError"  "()@:0\neval(\"()\")@:0\n([object Object],\"json\")
@https://jauldridge.yakabod.net/js/vne/jquery/core/jquery.js:29\ncb(-5)
@https://jauldridge.yakabod.net/js/vne/jquery/plugins/form/
jquery.form.js:305\n"

respectively.    adding a consol.log() of the XHR object which is
passed to the error function shows the mock object and it is still
empty.

Line 305 of the form plugin seems to be what is referenced in the odd
output of the error object, along with line 29 of jQuery.  Line 305 of
the form plugin is a call to jQuery's httpData method which is defined
on line 29 of jQuery.  Line 305 of the form plugin is supposed to be
taking what was retrieved from the textarea (I'm using JSON) of the
iframe and passing it to jQuery with my specified data type for
parsing.  Since this is all happening without any network activity,
and the mock object shows it is empty including its responseText, I
imagine that is why jQuery's httpData method is getting an error in
trying to parse JSON.

I just cannot figure this out, and I'd really like some help.  Why is
the plugin acting like it is done submitting when it hasn't even tried
to talk to the server?  This system is on a private network so I
cannot link to it, but I will provide as much info as is asked for and
I can obtain.

Thanks,
Jim

Reply via email to