Camera exif data are always undefined


Hi all, I have see this code:

var options = {
                quality: 100,
                targetWidth: 320,
                targetHeight: 320,
                saveToPhotoAlbum: true,
                destinationType: Camera.DestinationType.FILE_URI,
                sourceType: Camera.PictureSourceType.PHOTOLIBRARY
                    function(imageURI) {
                            function(entry) {
                                entry.file(function(file) {
                                    EXIF.getData(file, function() {
                                        var datetime = EXIF.getTag(this, "DateTimeOriginal");
                                    // do something useful....
                                }, function (e) {
                                    sharedService.log("resolveLocalFileSystemURL -> entry.file -> error",e);
                            function(e) {
                                alert('Unexpected error obtaining image file.');
                                sharedService.log("resolveLocalFileSystemURL -> error",e);
                    function() {
                        // nada - cancelled

For EXIF I use EXIF-js.js library.

Why datetime is always “undefined” ?
I have change Camera.PictureSourceType.PHOTOLIBRARY to Camera.PictureSourceType.CAMERA but with the same result.

I know that all my test images have EXIF data because if I open them with an EXIF extractor I can see all EXIF data.




Hi ziobudda,

Did you got any solution to your problem…If you got, can you please post it.

At present I’m looking to extract the date and lattitude,longitude from the image.

Can you please refer any solution.


My question - How to get the EXIF data(date & Location) of the Image?