I'm making an app using Ionic. It's almost done, but there is one problem. I am using ng-file-upload to upload files from the device. From iOS it asks if I want to upload from my gallery, or take a picture with the camera. From Android, it only asks from gallery, no camera option is showed.
I have read the whole documentation of ng-file-upload, and all the open and closed issues. None of them helped though.
I am using the following code:
<div class="thumbnail_box col col-25" ngf-select="addImage(picFile)" ngf-fix-orientation="true" ngf-capture="camera" ng-model="picFile" accept="image/*">
Tried a lot of different tags, such as:
ngf-capture="camera"
capture="camera"
no tag at all
If have also tried using a <button>
and <input type="file"...>
istead of a div
, which also don't work..
I have also tried it with, and without the Crosswalker-project. Doesn't seem to make any difference.. When I visit one of the examples of ng-file-upload on my browser on my Android phone, and press on the 'choose file' button, it does show the camera option..
Has anyone found a solution or workaround for this?
Any help appreciated!
Found the problem. Seems I had to add:
to the AndroidManifest xml file