Page 1 of 1
no results from REST service in web mobile pages
Posted: Thu Feb 20, 2014 11:42 am
by paul durrant
i have an external REST service in my app which in the data test screen gets the correct response, when i down load the app everything works fine, but in the online debug/test screen and the mobile web version no data gets displayed. i've tries creating a proxy but still the same result
no results from REST service in web mobile pages
Posted: Thu Feb 20, 2014 1:23 pm
by Kateryna Grynko
Hi Paul,
Do you pass the same parameters? Are there any console errors?
no results from REST service in web mobile pages
Posted: Thu Feb 20, 2014 2:23 pm
by paul durrant
taking a second look, one of the parameters is a date and it looks like the date is being passed differently between the app version and the web version, is there a way to detect what platform it is running on
no results from REST service in web mobile pages
Posted: Thu Feb 20, 2014 2:51 pm
by paul durrant
digging a little further i see this
Origin 'http://appery.io' is therefore not allowed access.
no results from REST service in web mobile pages
Posted: Thu Feb 20, 2014 2:58 pm
by paul durrant
resolved
added the following to web.config of the WCF service
system.webServer
httpProtocol
customHeaders
add name="Access-Control-Allow-Origin" value="*" /
/customHeaders
/httpProtocol
/system.webServer
with tags of course
no results from REST service in web mobile pages
Posted: Thu Feb 20, 2014 3:08 pm
by Kateryna Grynko
Paul,
Thank you for the update!