Im using childbrowser plugin for phone gap in my android application to view my external site. Is there a way to activate camera on a button tap on that external site ? I tried adding code bellow to my on button tap function but it doesnt work.
pictureSource=navigator.camera.PictureSourceType;
destinationType=navigator.camera.DestinationType;
navigator.camera.getPicture(onSuccess, onFail, { quality: 50,
destinationType: destinationType.DATA_URL });
function onFail(message) {
alert('Failed because: ' + message);
}
function onSuccess(message) {
alert('Success because: ' + message);
}
And to run childbrowser(which works fine) I use:
window.plugins.childBrowser.showWebPage(_url, { showLocationBar: false });