cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nikhil Khandelwal (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CB-10069) Using either file:/// or cdvfile:// as the <img src=""> causes errors
Date Sat, 09 Jan 2016 01:25:39 GMT

     [ https://issues.apache.org/jira/browse/CB-10069?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Nikhil Khandelwal updated CB-10069:
-----------------------------------
    Labels: Windows10 triaged wfc  (was: Windows10)

> Using either file:/// or cdvfile:// as the <img src=""> causes errors
> ---------------------------------------------------------------------
>
>                 Key: CB-10069
>                 URL: https://issues.apache.org/jira/browse/CB-10069
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Plugin File
>    Affects Versions: 5.4.0
>         Environment: Windows, Cordova Whitelist, Cordova File, Cordova File Transfer
>            Reporter: Katie Egervari
>            Priority: Minor
>              Labels: Windows10, triaged, wfc
>
> Trying to load an image from the local filesystem using fileEntry.toURL() does not work
(I have tried toInternalURL() and toNativeURL() as well). In Chrome, it says:
>                  Not allowed to load local resource: file:///persistent/spotlight5/image_8a8a8a4c45698eba01456b127db5015b
> When trying to use the cdvfile:// address instead results in this error:
>          cdvfile://localhost/persistent/spotlight5/image_8a8a8a4c45698eba01456b127db5015b:1
GET cdvfile://localhost/persistent/spotlight5/image_8a8a8a4c45698eba01456b127db5015b net::ERR_UNKNOWN_URL_SCHEME
> I have tried countless configurations of whitelist and/or the content security policy.
My current configurations (but this is NOT limited to what I have actually tried) are:
>     <allow-navigation href="http://*/*"/>
>     <allow-navigation href="file:///*" />
>     <allow-navigation href="cdvfile://*" />
>     <allow-intent href="http://*/*" />
>     <allow-intent href="https://*/*" />
>     <allow-intent href="file:///*" />
>     <allow-intent href="cdvfile://*" />
>     <access origin="http://*/*" />
>     <access origin="https://*/*" />
>     <access origin="cdvfile://*" />
>     <access origin="file:///*" />
> And
>         <meta http-equiv="Content-Security-Policy"
>               content="default-src * 'unsafe-inline' 'unsafe-eval'">
> I really need help with this one, as this is blocking me finishing my project. This application
has to run standalone, and we have to download images dynamically, put them on the local file
system of the device, and then show them in image tags when disconnected from the network.
> Thank you.
> Katie



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Mime
View raw message