PDA

View Full Version : Changing "Accept" header of the AJAX Request



1099511627776
23 May 2012, 9:45 PM
Hello, guys,
How can I change the default HTTP header - "Accept" when requesting data into the store (with AJAX proxy ) from
"Accept: */*" to "Accept: application/json" for example.

mitchellsimoens
25 May 2012, 12:23 PM
Have you tried with the defaultHeaders property of Ext.Ajax?

1099511627776
26 May 2012, 7:15 AM
I think this is it. Thanks.
But what IF I have 2 stores, one with JSON Proxy, and one with XML Proxy. and the server is configured to sent differect responses according to client's Accept header