Vladimir
Vladimir

Reputation: 61

Force window.postMessage to do a POST instead of a GET

Is there a way to convince window.postMessage (https://developer.mozilla.org/en/DOM/window.postMessage) make a POST and not a GET? Probably not, although I couldn't find this limitation in the docs.

Upvotes: 0

Views: 79

Answers (1)

Quentin
Quentin

Reputation: 943922

postMessage does not (and cannot) make any kind of HTTP request. It causes a message event to be fired in the JavaScript environment of the target window.

JavaScript in the document loaded in the target window might respond to the event by doing something that triggers an HTTP request, but that is specific to the code in that page.

Upvotes: 2

Related Questions