Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 49418

Ng-src 404 error on different page

$
0
0

@Luonic wrote:

Hello.
I'm having issue with loading image in nested page. In parent page images loaded great.
I store links to external images loaded with imagePicker (file:///...) in sqlite, sqlite is working great, on second page variable "post" is populated with data, everything should work...
I've googled all possible keyword combinations and did not found anything what will help me.

This is part of code for parent page

This is my sanitization config

.config( ['$compileProvider',function( $compileProvider ){
$compileProvider.imgSrcSanitizationWhitelist(/^\s(https|file|blob|cdvfile):|data:image\//);
}])

config.xml

CSP

<https://ssl.gstatic.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src 'self' 'unsafe-eval' data:; img-src * data:" />

.config(function ($stateProvider, $urlRouterProvider) {
    $stateProvider
        .state('conig', {
            url: '/config',
            templateUrl: 'views/ConfigView.html',
            controller: 'ConfigCtrl'
        })
        .state('queue', {
            url: '/queue',
            templateUrl: 'views/QueueView.html',
            controller: 'QueueCtrl',
        })
        .state('add', {
            url: '/add',
            templateUrl: 'views/AddView.html',
            controller: 'AddCtrl'
        })
        .state('edit', {
            url: '/edit/:UID',
            templateUrl: 'views/EditView.html',
            controller: 'EditCtrl',
        })
    $urlRouterProvider.otherwise('/queue');
})

EditView.html (my second (child) page)

This is parent page and everything is fine
I press "Edit" button and navigating to second page

This is second page and image not loaded

Console:

Failed to load resource: the server responded with a status of 404 (Not Found)
post.imgUri (0,0)

Please help

Posts: 2

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 49418

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>