I am currently developing a website for mobile devices. The website needs to analyze pictures taken from the camera of the phone. I currently grab the image data via:
<input type="file" id="input_photo" accept="image/*;capture=camera" capture="camera"/>
However on all Android devices I tested (Android is the main plattform for now) and for all browsers (Stock Browser, Chrome, Firefox) the image is either saved to /sdcard/DCIM/browser_photos/ or simply /sdcard/.
I don’t need those pictures so my question is, if there is a way to either let the browser know to not save those pictures permanently or to delete those pictures after analyzing them.
PhoneGap or similar APIs are not an option. I want to stick to pure HTML5 and JavaScript.
Thanks for your help
You just cannot access device’s storage to remove something from the browser – it will be a security issue. The same thing is with regular OS browsers – the only thing you can do is use a file input to browse for file to upload – nothing more.