Hi Peter,
A “hack”? I just followed the documentation:
beforeSend(jqXHR, settings): A pre-request callback function that can be used to modify the jqXHR
There is no exemples on usage.
How can I set a request authorization header using the contentType?
And how to use this library to access the Twitter API, for exemple, that also requires an Authorization header? For exemple:
POST /1/statuses/update.json?include_entities=true HTTP/1.1
Accept: */*
Connection: close
User-Agent: OAuth gem v0.4.4
Content-Type: application/x-www-form-urlencoded
Authorization: OAuth oauth_consumer_key="xvz1evFS4wEEPTGEFPHBog", ...
Content-Length: 76
Host: api.twitter.com
There is the Content-Type AND there is the Authorization headers. The question is: How to set that Authorization header?
Best regards,