PDA

View Full Version : Cross-domain policy with sencha touch



debraph
17 Nov 2011, 12:42 AM
hello,

I just want to know why with the offline example (http://www.sencha.com/learn/taking-sencha-touch-apps-offline/) we can access to a remote web service directly in the JS, without any PHP or other server-side technology proxy ?

Because of the cross-domain policy, we havn't the right to make a request to a remote service.

I think it is because Sencha Touch made the work for us, but I don't understand where and how?

Thank you for your future comments !

AndreaCammarata
17 Nov 2011, 10:53 AM
Hi.
That's because the store used by the app uses a "scripttag" proxy.
You can find more informations on it at the following documentation page:

http://docs.sencha.com/touch/1-1/#!/api/Ext.data.ScriptTagProxy

Hope this helps.

debraph
17 Nov 2011, 12:27 PM
Thank you for your answer