Re: POST NSURLRequest, send Response to Web Browser
Re: POST NSURLRequest, send Response to Web Browser
- Subject: Re: POST NSURLRequest, send Response to Web Browser
- From: Jens Alfke <email@hidden>
- Date: Fri, 11 Jul 2008 16:52:39 -0700
On 11 Jul '08, at 11:07 AM, Jerry Krinock wrote:
I think I've figured out the answer. Instead of sending the POST
using NSURLConnection, I'm going to write a little temporary html
file. This little html file will have an onLoad() javascript which
immediately sends the POST, and a button for users that don't have
javascript enabled. Now, tell NSWorkspace to open ^this^ temporary
file. Now, Safari sends the POST, thus Safari gets back the
response. Seems like it should work.
That's an interesting approach. I assume the HTML will contain a
dynamically generated <form> that points to the right URL and has the
right input fields already filled out?
This issue of "sending a POST to the browser" has come up before, in
the context of emails containing forms. Mail.app has never handled
such forms, for exactly these reasons; but this little HTML idea might
be a decent solution.
—Jens
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden