Page 4 of 4

Image from file system

Posted: Mon Jan 06, 2014 6:55 am
by Kateryna Grynko

Hi Mehmet,

You can add an image path:preAppery("mobileimage").attr("src","file:///path/filename");/pre
codefile:///path/filename/code is a full path to a file on device.


Image from file system

Posted: Mon Jan 06, 2014 7:21 pm
by Mehmet Edebali Şener

Image

I changed page a little bit, add an image below of grid named “fimage". “pimage" is an image upper side where is in grid.

Appery("fimage").attr("src","file:///storage/sdcard0/SureTermse/Aa.jpg”);
is working correctly and changes image

however
$("[dsid=pimage]", element.parent()).attr("src","file:///storage/sdcard0/SureTermse/Aa.jpg”);
Appery(“pimage").attr("src","file:///storage/sdcard0/SureTermse/Aa.jpg”);
is not working.

So I think maybe image elements not correctly fetching. I give a default image from editor. Then try to alert its source like:
alert($("[dsid=pimage]", element.parent()).attr("src"));
this is working too. Alerting image source correctly.

So referencing in grid is working. sourcing image from local storage is working. But both of them together fails. :s


Image from file system

Posted: Mon Jan 06, 2014 9:46 pm
by Maryna Brodina

Hello! Could you clarify on what event you add this code pre$("[dsid=pimage]", element.parent()).attr("src","file:///storage/sdcard0/SureTermse/Aa.jpg”);/pre


Image from file system

Posted: Mon Jan 06, 2014 10:28 pm
by Mehmet Edebali Şener

I have a database service. One element on this service connected to invisible label. I add javascript to these reference like that. There isn't any logic behind that. This is just case study to clarify problem.

Image


Image from file system

Posted: Mon Jan 06, 2014 10:51 pm
by Mehmet Edebali Şener

If you need to check, project already shared with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a

Project Name : SureTerms
Page Name : ListPackagesPage

On start screen of app clicking "MyPacks" button navigates this page.

By the way another topic which I tried and fail
https://getsatisfaction.com/apperyio/...


Image from file system

Posted: Wed Jan 08, 2014 9:11 pm
by Maryna Brodina

Hello! Working on it...


Image from file system

Posted: Thu Jan 09, 2014 11:08 am
by Kateryna Grynko

Hi Mehmet,

Are you sure you use correct path for image file:///storage/sdcard0/ ?

The path can differ, for example:
file://sdcard
file://mnt/sdcard
etc.

Why did you choose this one file:///storage/sdcard0/ ?