These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Submitting forms on a mac

nixopax
Registered: Feb 6 2009
Posts: 105

Hi there, I have a form that submits to a PHP script that deposits the form data into a MySQL database. I use submitForm() as the method as such:

submitForm({
cURL: "http://server.com/script.php#FDF",
aFields:null,
cSubmitAs: "HTML"});

On Windows, both Acrobat Pro and Reader submit to the database without issue.

On a Mac, only Acrobat Pro submits successfully. Reader accesses the page, and receives the FDF response I have at the end of the script, but nothing is being passed.

I've set up a catch on the PHP script to e-mail me all variables being sent, both GET and POST, as well as some other information. Reader gives me the user-agent: AcroForms, and Pro gives me a browser user-agent response, Mozilla for Windows and Safari for Mac. So it isn't an issue with reader on Windows, because it sends an AcroForm response with POST data, but the reader on the Mac only sends an AcroForm response, but no data.

I've scoured the Javascript API reference for the submitForm for any gotcha that may be Mac exclusive, but got nothing. I have also tried removing the #FDF from the end of the cURL, thinking maybe the Mac interpreted it as how to send it in an FDF rather than url-encoded HTML, but that came back with an empty response as well.

Is there some special way to send POST data that I'm missing? By default bGet is false.

Edit: Another thing I've just tested was on Mac, opening the PDF file in Safari, the form submitted, but gave me an error message that I needed the #FDF at the end of the URL, so I went back, put it in, and it worked. But it still doesn't work in Reader on Mac.

My Product Information:
Reader 9.0, Macintosh
George_Johnson
Expert
Registered: Jul 6 2008
Posts: 1876
You need to tell us what type of response the server is returning. Is the form submitting outside of a browser?

George
nixopax
Registered: Feb 6 2009
Posts: 105
The server responds with an FDF.
The forms are submitted outside the browser.
George_Johnson
Expert
Registered: Jul 6 2008
Posts: 1876
Someone the other day was reporting a problem with submitting form data on the Mac. Have you tried Reader-enabling the form? When you do so in Acrobat Pro, it adds the "Submit Standalone" usage right, which is supposed to be what Reader needs to submit outside of a web browser.

George
nixopax
Registered: Feb 6 2009
Posts: 105
Do you perhaps mean [b][u]A[/u]dvanced > Exte[u]n[/u]d Features in Adobe Reader[/b]?I've just attempted that, and still in the same boat. On another note, I have a mac with Reader 7, and as a standalone reader, I can submit the form without issue. This seems to be isolated solely to Mac Reader 9.
George_Johnson
Expert
Registered: Jul 6 2008
Posts: 1876
Yes, that's what I meant.

For another report of problems submitting with the Mac, see: http://www.acrobatusers.com/forums/aucbb/viewtopic.php?id=18628

No solutions, but it may be of interest.

George
nixopax
Registered: Feb 6 2009
Posts: 105
I'll keep my eye on that thread as well. So far, my only solution is to ensure Mac Reader 9 is opened in the browser, otherwise, it's all good. I've submitted a bug report to Adobe, so it'll only be a matter of time before it gets fixed. I've got Beta 9.1 too, so I'll try it later.