Mobile App: Server Connect working in Emulator but not in the Device

Hello Everybody.

I started to try to make an Android App but I got the following problem: the server connect action works (just listing a table) perfectly in the Emulator, but doesn t works on the Device.

I added in the meta section the field:

then I select BOOTSTRAP framework to work with (I started a new page).

In the emulator the server connect works well and I got the feeding of the table.
In the device nothing. It seems have no connection with server connect.

Any suggestion please ?

App_mobile

Thank you

Roberto

CORS issue

thank you @s.alpaslan.
I set in the config.xml both website, the ain domain and direct address of the script:

 <allow-intent href="https://hub.xxxxxxx.com//*/*"/>
 <allow-intent href="https://hub.xxxxxcom/dmxConnect/api/glossary/xxxxx.php/>

in the meta field in the page I wrote security policy:

<meta http-equiv="X-Content-Security-Policy" content="img-src 'self' data:; default-src 'self' 'unsafe-inline'; https://hub.xxxxxxx.com/*/ https://*/ https://xxxxx.com/*/ script-src 'self' 'unsafe-eval'; object-src 'self';">
do I need to set up other points?

thank you for your support

You have to allow cors in server side . so CSP is not enought

I m loosing myself, sorry, where in the server side I can allow cors?

Do you mean server side inside wappler or speaking about server?

This is for plesk panel

You can find similar configuration for other hosting panels

OK i got it thank you very much !!

1 Like