Fxster
Fxster

Reputation: 189

Phonegap image not loading from a external http

my phonegap app was working well using phonegap 4.0.

Just upgraded to 6.0, using the same codes. These images loaded from self is loaded, but those from external http is not loaded. eg http://www.hihi.com. I tried changing meta CSP settings and also config.xml, both not helping.

config.xml

<access origin="*"></access>
<allow-navigation href="http://*/*" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" /> 
<allow-intent href="*" />

index.html (added img-src *)

<meta http-equiv="Content-Security-Policy" content="default-src * 'unsafe-inline';img-src *; style-src 'self' 'unsafe-inline'; media-src *" />

any other reasons? I am running from phonegap desktop server and phonegap mobile app

Upvotes: 1

Views: 1183

Answers (1)

Fxster
Fxster

Reputation: 189

ok. know the reason but not solved. it is because phonegap desktop server app overwrites our own CSP settings.

Link github.com/phonegap/connect-phonegap/issues/163 – Fxster 43 mins ago edit

Images is loading when installed into phone

Upvotes: 0

Related Questions