Set Request Header if requesting data from server

0 views
Skip to first unread message

Merhawie

unread,
May 22, 2009, 10:53:07 PM5/22/09
to Gears Users
Not really a gotcha, but if you are using "beta.httprequest" and
cannot get data with responseText make sure this is set on your
request:
request.setRequestHeader("Content-type","application/x-www-form-
urlencoded");

Otherwise, I couldnt get it to work (I only checked with POST, not
sure about PUT and GET)
Reply all
Reply to author
Forward
0 new messages