Looks good. And what's in the request that is logged? You do know what the green colour means?
Printable View
Looks good. And what's in the request that is logged? You do know what the green colour means?
I miscopied the header. You need
Code:Ext.lib.Ajax.useDefaultXhrHeader = false;
Now it works for normal Ajax request, but not when I add custom headers. Let me give a full example, so you can try it out (assuming you have a gmail/google account somewhere):
Visit this url to request a temporary security token: AuthSubRequest. The site will ask for permission. If you grant permission, you will be fowarded to Extjs.com?token=sometokenhere. This token is a temporary token that you can exchange for a session token using this request:
The response for this request should contain a new token, that you can use to access google services. Note that it is important that the authorization header should be exactly in the form AuthSub token="asdf8sdjksdu8ds8g", and you can use every temp token only once.Code:Ext.Ajax.request({
url:"https://www.google.com/accounts/AuthSubSessionToken",
method: "GET",
headers:{'authorization':'AuthSub token="temp_token_here_between_the_quotes"'},
success: function(xhr){alert(xhr.responseText)}
});
Any one got Solution to this problem..?? I am also getting 405 error.....
.
In an Ajax call instead of GET, the browser is running OPTION method.. :( :( :(
.
.
Any help appreciated.
Thanks