Erjan
Posts: 0
Joined: Mon Jul 21, 2014 7:57 am

Image cannot load

Hi Support

I have followed your tutorial on loading the image from dbase.
Appery("workShop_Logo").attr('src', Appery.getImagePath('audi_logo.png'));

But when I test it out, No image at all. The html page was showing...
Image

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Image cannot load

Hello Erjan,

This code displays the image not from the database, but from one of those images that have been uploaded via the Media Manager.
If you want to display the image from the database, you must provide a link to it in this form, as it is shown here:
http://devcenter.appery.io/documentat...
And, for example, save it in a url variable, then your code will look like:
preAppery("workShop_Logo").attr('src', url);/pre

Erjan
Posts: 0
Joined: Mon Jul 21, 2014 7:57 am

Image cannot load

Sorry mistypo, what I mean is want to load image from media manager.
I have tried to clear the cache but no success.

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Image cannot load

Erjan,

Could you please check, do you have the image audi_logo.png in Media Manager? Could you please provide is the public a link to your application?

Erjan
Posts: 0
Joined: Mon Jul 21, 2014 7:57 am

Image cannot load

Yes i have the image, the link is appery.io/app/view/7c91c074-1e1f-40d8-8d50-f2031a2de485/startPage.html

obullei
Posts: 0
Joined: Thu Jun 05, 2014 12:17 am

Image cannot load

Hello!

Please provide us your login and password and steps to reproduce.

Erjan
Posts: 0
Joined: Mon Jul 21, 2014 7:57 am

Image cannot load

Just send the detail to your support email

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

Image cannot load

Hi Erjan,

I've checked your app and see following error:

you have code:

pre

Appery("workShop_Logo").attr("src", Appery.getImagePath(localStorage.getItem('var_workshopLogo')));

/pre

in this code you get imageName from "var_workshopLogo" LSV thus you should have in this LSV correct value. But currently there is "null". Did you forget set it?

see details on screen shot:

http://prntscr.com/4am1hu/direct

Regards.

Erjan
Posts: 0
Joined: Mon Jul 21, 2014 7:57 am

Image cannot load

Hi Yurii,

I have commented the above mentioned line. So now i will put the actual filename, still cannot load the image.

Thanks

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

Image cannot load

Hi Erjan,

Still see that you try to get correct image name from LSV "var_workshopLogo". But there is still "null".

Please use following code near your code to see in browser console what are you have in your LSV "var_workshopLogo".

pre

//Code to log in browser console.
console.log("var_workshopLogo = " + localStorage.getItem('var_workshopLogo'));

//Your code.
Appery("workShop_Logo").attr("src", Appery.getImagePath(localStorage.getItem('var_workshopLogo')));

/pre

After this code you will need open browser console and you will see here what you have in this LSV.

Regards.

Return to “Issues”