I am trying to build an app using Extjs and ColdFusion. I have decided to use openBD for Coldfusion server so, i set up a Tomcat servlet. The ExtJs 4.1 lib and code are on Apache server. While on the same machine Apache and Tomcat uses different ports. This is a clasic SOP situation. In order to handle this restriction i had to use either jsonP or CORS. People here in the Sencha's forum helped me with the jsonP solution (thanks) but i needed to implement CORS. I had tuned up Tomcat for CORS, expecting Ext to be working out of the box! But no it didn't. While trying few things i placed the following code block in my app.js:
and like a miracle CORS worked!
"Ext.data.Connection.prototype.useDefaultXhrHeader = false;"
Why the above snippet worked? I think that it is ST (Touch) related code. It would be very nice if i learn something new!