View Full Version : Web Apps and Mobile Phone Cameras

2016-11-30, 11:03
When viewing a Lianja Web App (not a native app) on a mobile device, is it possible to allow users to upload a picture directly from the camera? i.e. when they touch an image, the upload dialogue would include a "take a picture" option or something similar.


Rob C

2016-11-30, 11:34
Hi Rob,

Just touch the picture and you can choose to take a photo or select an existing one. It is uploaded automatically for you and either inserted or updated in the table it is bound too.

See thread "[Answers] Image": http://www.lianja.com/community/showthread.php?2828-Answers-Image (post #3)

Also common method GetPicture:

Take a photo using the camera or retrieve a photo from the device's image gallery. Returns a file URI or base64 string. If cameraOptions isnot specified, a source selection prompt is displayed and the file URI is returned. (From v2.0).

Question: If I use PhoneGap do I have any access to the camera?

Answer: Yes, that's the whole point of PhoneGap. It provides a layer of abstraction above the device platform (iOS or Android) so that you can build cross platform Apps.


2016-11-30, 12:53

The post to which you refer is talking about a native mobile app. I understand that if I create a mobile app and use data binding the user can touch the image and upload a file or directly from the camera.

Does this also apply to a Web App viewed from a mobile phone?


Rob C

2016-11-30, 19:23
Hi Rob,

Have you tried it?

There are many examples on stack overflow too.

2016-12-01, 04:11

I haven't given it a try yet as I'm having difficulties accessing the cloud server from my mobile phone and I haven't had time to investigate that issue yet. I'm pretty sure it's a local network issue as I can access and login but then the app centre appears to hang on loading. I will probably have time to work out what's wrong over the weekend. I can access the system from my Galaxy tablet but I get "missing tablet_index.html" errors on login and I've found that the system isn't creating the required tablet_index.html though I have no idea why at this point.

I have read over the stack overflow entries about using the HTML5 input/capture tags so I know it can be done in HTML5 and assume it can be done in Lianja but I was hoping for confirmation. I will assume that the answer is yes though again, I would prefer not to have to assume anything. This is why I've asked the question here.

If I had time to test every aspect of Lianja myself, I would but I don't so I ask instead. I did search the developer's guide and the forum posts for answers to my questions before asking but the answers are not available as far as I can see. That being the case, I thought this was the proper place to ask my questions.


Rob C