{"_id":"exif-js","_rev":"347261","name":"exif-js","description":"JavaScript library for reading EXIF image metadata","dist-tags":{"iptc-primer":"2.2.0","latest":"2.3.0"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"time":{"modified":"2021-06-22T09:59:55.000Z","created":"2014-05-02T08:19:34.521Z","2.3.0":"2017-09-10T20:41:59.391Z","2.2.3":"2017-09-10T19:10:45.319Z","2.2.1":"2017-04-03T20:12:02.227Z","2.2.0":"2017-03-31T11:20:25.058Z","2.1.1":"2015-08-07T12:17:47.103Z","2.1.0":"2015-08-07T11:41:05.727Z","2.0.0":"2015-08-07T11:00:54.998Z","1.0.7":"2014-05-02T08:19:34.521Z"},"users":{"anker":true,"awen1983":true,"wayn":true,"strugglexiang":true,"faraoman":true,"dallinrparker":true,"yanghcc":true,"flitrue":true},"author":{"name":"Jacob Seidelin"},"repository":{"type":"git","url":"git+https://github.com/exif-js/exif-js.git"},"versions":{"2.3.0":{"name":"exif-js","version":"2.3.0","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/exif-js/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"license":"MIT","bugs":{"url":"https://github.com/exif-js/exif-js/issues"},"homepage":"https://github.com/exif-js/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"devDependencies":{"bower":"^1.4.2","mversion":"^1.10.0"},"gitHead":"a10f3d53f3f72defef4cad5a54a90ee308901fe6","_id":"exif-js@2.3.0","scripts":{},"_shasum":"9d10819bf571f873813e7640241255ab9ce1a814","_from":".","_npmVersion":"3.10.10","_nodeVersion":"6.11.0","_npmUser":{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},"dist":{"shasum":"9d10819bf571f873813e7640241255ab9ce1a814","size":1241188,"noattachment":false,"key":"/exif-js/-/exif-js-2.3.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.3.0.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/exif-js-2.3.0.tgz_1505076117284_0.5361941244918853"},"publish_time":1505076119391,"_cnpm_publish_time":1505076119391,"_hasShrinkwrap":false},"2.2.3":{"name":"exif-js","version":"2.2.3","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/exif-js/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"license":"MIT","bugs":{"url":"https://github.com/exif-js/exif-js/issues"},"homepage":"https://github.com/exif-js/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"devDependencies":{"bower":"^1.4.2","mversion":"^1.10.0"},"gitHead":"69a7d08883592f9611cddcc75b2aedab6bc59a06","_id":"exif-js@2.2.3","scripts":{},"_shasum":"2bf8bd05755f87d47404cddcb051c052a88b9cb0","_from":".","_npmVersion":"3.10.10","_nodeVersion":"6.11.0","_npmUser":{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},"dist":{"shasum":"2bf8bd05755f87d47404cddcb051c052a88b9cb0","size":818111,"noattachment":false,"key":"/exif-js/-/exif-js-2.2.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.2.3.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/exif-js-2.2.3.tgz_1505070643694_0.6905360224191099"},"publish_time":1505070645319,"_cnpm_publish_time":1505070645319,"_hasShrinkwrap":false},"2.2.1":{"name":"exif-js","version":"2.2.1","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/exif-js/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"license":"MIT","bugs":{"url":"https://github.com/exif-js/exif-js/issues"},"homepage":"https://github.com/exif-js/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"devDependencies":{"bower":"^1.4.1","mversion":"^1.10.0"},"gitHead":"9221a42fd74b90120ffc06be6e1ba248562fd014","_id":"exif-js@2.2.1","scripts":{},"_shasum":"68589104759cafff97c396fafae4b428e87d2159","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.5.0","_npmUser":{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},"dist":{"shasum":"68589104759cafff97c396fafae4b428e87d2159","size":818094,"noattachment":false,"key":"/exif-js/-/exif-js-2.2.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.2.1.tgz"},"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/exif-js-2.2.1.tgz_1491250321635_0.002274568658322096"},"publish_time":1491250322227,"_hasShrinkwrap":false,"_cnpm_publish_time":1491250322227},"2.2.0":{"name":"exif-js","version":"2.2.0","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/exif-js/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"license":"MIT","bugs":{"url":"https://github.com/exif-js/exif-js/issues"},"homepage":"https://github.com/exif-js/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"devDependencies":{"bower":"^1.4.1","mversion":"^1.10.0"},"gitHead":"673f1b3ac3517da7b59f086a626b2d517a68ef3f","_id":"exif-js@2.2.0","scripts":{},"_shasum":"ca03d88cc25e6ae8cb8c415dc1e36d4470a9a590","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.5.0","_npmUser":{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},"dist":{"shasum":"ca03d88cc25e6ae8cb8c415dc1e36d4470a9a590","size":818092,"noattachment":false,"key":"/exif-js/-/exif-js-2.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.2.0.tgz"},"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/exif-js-2.2.0.tgz_1490959224335_0.10438646422699094"},"publish_time":1490959225058,"_cnpm_publish_time":1490959225058,"_hasShrinkwrap":false},"2.1.1":{"name":"exif-js","version":"2.1.1","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/exif-js/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"license":"MIT","bugs":{"url":"https://github.com/exif-js/exif-js/issues"},"homepage":"https://github.com/exif-js/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"devDependencies":{"bower":"^1.4.1","mversion":"^1.10.0"},"gitHead":"ba94836672aad1df609b9894ea06b2c145ec7a1a","_id":"exif-js@2.1.1","scripts":{},"_shasum":"2962e6aa6600340a454b24c52e458b81ccf1e6d6","_from":".","_npmVersion":"2.11.3","_nodeVersion":"0.12.7","_npmUser":{"name":"webthusiast","email":"info@webthusiast.nl"},"dist":{"shasum":"2962e6aa6600340a454b24c52e458b81ccf1e6d6","size":812841,"noattachment":false,"key":"/exif-js/-/exif-js-2.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.1.1.tgz"},"publish_time":1438949867103,"_cnpm_publish_time":1438949867103,"_hasShrinkwrap":false},"2.1.0":{"name":"exif-js","version":"2.1.0","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/jseidelin/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"license":"MIT","bugs":{"url":"https://github.com/jseidelin/exif-js/issues"},"homepage":"https://github.com/jseidelin/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"devDependencies":{"bower":"^1.4.1","mversion":"^1.10.0"},"gitHead":"e394ac54d69ae2d8546509c82534aa9c4afa87b9","_id":"exif-js@2.1.0","scripts":{},"_shasum":"9c5f1eb4fe4d1ee2a6d97040b9762a72ea48f649","_from":".","_npmVersion":"2.11.3","_nodeVersion":"0.12.7","_npmUser":{"name":"webthusiast","email":"info@webthusiast.nl"},"dist":{"shasum":"9c5f1eb4fe4d1ee2a6d97040b9762a72ea48f649","size":812825,"noattachment":false,"key":"/exif-js/-/exif-js-2.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.1.0.tgz"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"publish_time":1438947665727,"_cnpm_publish_time":1438947665727,"_hasShrinkwrap":false},"2.0.0":{"name":"exif-js","version":"2.0.0","description":"JavaScript library for reading EXIF image metadata","main":"exif.js","directories":{"example":"example"},"repository":{"type":"git","url":"git+https://github.com/jseidelin/exif-js.git"},"keywords":["exif"],"author":{"name":"Jacob Seidelin"},"license":"MIT","bugs":{"url":"https://github.com/jseidelin/exif-js/issues"},"homepage":"https://github.com/jseidelin/exif-js","ignore":["**/.*","node_modules","bower_components","test","tests","spec","example"],"gitHead":"158e3510d6bb284b1653dca2e2642f63a67c5858","_id":"exif-js@2.0.0","scripts":{},"_shasum":"82f8a95f4ddaf062d0280e384dae70fd4b0c51bb","_from":".","_npmVersion":"2.11.3","_nodeVersion":"0.12.7","_npmUser":{"name":"webthusiast","email":"info@webthusiast.nl"},"dist":{"shasum":"82f8a95f4ddaf062d0280e384dae70fd4b0c51bb","size":812849,"noattachment":false,"key":"/exif-js/-/exif-js-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-2.0.0.tgz"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"publish_time":1438945254998,"_cnpm_publish_time":1438945254998,"_hasShrinkwrap":false},"1.0.7":{"name":"exif-js","version":"1.0.7","description":"A JavaScript library for reading EXIF meta data from JPEG image files.","main":"exif.js","directories":{"example":"example"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"git://github.com/webthusiast/exif-js"},"homepage":"https://github.com/webthusiast/exif-js","bugs":{"url":"https://github.com/jseidelin/exif-js/issues"},"keywords":["exif","binaryajax","nihilogic","browserify","commonjs"],"author":{"name":"Jacob Seidelin","email":"jseidelin@nihilogic.dk","url":"http://blog.nihilogic.dk/"},"maintainers":[{"name":"bartvanderwal","email":"bartvanderwal@gmail.com"},{"name":"jseidelin","email":"jseidelin@nihilogic.dk"},{"name":"webthusiast","email":"info@webthusiast.nl"}],"license":"MIT","_id":"exif-js@1.0.7","_shasum":"694e64ec8f33c259989998ffe0305db8793d5998","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"webthusiast","email":"info@webthusiast.nl"},"dist":{"shasum":"694e64ec8f33c259989998ffe0305db8793d5998","size":805482,"noattachment":false,"key":"/exif-js/-/exif-js-1.0.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/exif-js/download/exif-js-1.0.7.tgz"},"publish_time":1399018774521,"_cnpm_publish_time":1399018774521,"_hasShrinkwrap":false}},"readme":"# Exif.js\n\nA JavaScript library for reading [EXIF meta data](https://en.wikipedia.org/wiki/Exchangeable_image_file_format) from image files.\n\nYou can use it on images in the browser, either from an image or a file input element. Both EXIF and IPTC metadata are retrieved.\nThis package can also be used in AMD or CommonJS environments.\n\n**Note**: The EXIF standard applies only to `.jpg` and `.tiff` images. EXIF logic in this package is based on the EXIF standard v2.2 ([JEITA CP-3451, included in this repo](/spec/Exif2-2.pdf)).\n\n## Install\nInstall `exif-js` through [NPM](https://www.npmjs.com/#getting-started):\n\n    npm install exif-js --save    \n\nOr [Bower](http://bower.io/):\n\n    bower install exif-js --save\n\nThen add a `script` tag in your an HTML in the [best position](http://stackoverflow.com/questions/436411/where-is-the-best-place-to-put-script-tags-in-html-markup) referencing your local file.\n\n    <script src=\"vendors/exif-js/exif-js\"></script>\n\n**Note**: This repo has no `.min.js`. Do your own [minification](https://en.wikipedia.org/wiki/Minification_(programming)) if you want that.\n\nIf you prefer another package manager you will probably manage :D. Or you can clone this GIT repository or download it's ZIP file and extract `exif.js` to your project.\n\n## Usage\nThe package adds a global `EXIF` variable (or AMD or CommonJS equivalent).\n\nStart with calling the `EXIF.getData` function. You pass it an image as a parameter:\n- either an image from a `<img src=\"image.jpg\">`\n- OR a user selected image in a `<file type=\"input\">` element on your page.\n\nAs a second parameter you specify a callback function. In the callback function you should use `this` to access the image with the aforementioned metadata you can then use as you want.\nThat image now has an extra `exifdata` property which is a Javascript object with the EXIF metadata. You can access it's properties to get data like the *image caption*, the *date a photo was taken* or it's *orientation*.\n\nYou can get all tages with `EXIF.getTag`. Or get a single tag with `EXIF.getTag`, where you specify the tag as the second parameter.\nThe tag names to use are listed in `EXIF.Tags` in `exif.js`.\n\n**Important**: Note that you have to wait for the image to be completely loaded, before calling `getData` or any other function. It will silently fail otherwise.\nYou can implement this wait, by running your exif-extracting logic on the `window.onLoad` function. Or on an image's own `onLoad` function.\nFor jQuery users please note that you can NOT (reliably) use jQuery's `ready` event for this. Because it fires before images are loaded.\nYou could use $(window).load() instead of $(document.ready() (please note that `exif-js has NO dependency on jQuery or any other external library). \n \n**JavaScript**:\n```javascript\nwindow.onload=getExif;\n\nfunction getExif() {\n    var img1 = document.getElementById(\"img1\");\n    EXIF.getData(img1, function() {\n        var make = EXIF.getTag(this, \"Make\");\n        var model = EXIF.getTag(this, \"Model\");\n        var makeAndModel = document.getElementById(\"makeAndModel\");\n        makeAndModel.innerHTML = `${make} ${model}`;\n    });\n\n    var img2 = document.getElementById(\"img2\");\n    EXIF.getData(img2, function() {\n        var allMetaData = EXIF.getAllTags(this);\n        var allMetaDataSpan = document.getElementById(\"allMetaDataSpan\");\n        allMetaDataSpan.innerHTML = JSON.stringify(allMetaData, null, \"\\t\");\n    });\n}\n```\n\n**HTML**:\n```html\n<img src=\"image1.jpg\" id=\"img1\" />\n<pre>Make and model: <span id=\"makeAndModel\"></span></div>\n<br/>\n<img src=\"image2.jpg\" id=\"img2\" />\n<pre id=\"allMetaDataSpan\"></pre>\n<br/>\n```\n\nNote there are also alternate tags, such the `EXIF.TiffTags`. See the source code for the full definition and use.\nYou can also get back a string with all the EXIF information in the image pretty printed by using `EXIF.pretty`.\nCheck the included [index.html](/exif-js/exif-js/blob/master/index.html).\n\nPlease refer to the [source code](exif.js) for more advanced usages such as getting image data from a [File/Blob](https://developer.mozilla.org/en/docs/Web/API/Blob) object (`EXIF.readFromBinaryFile`).\n\n## Contributions\nThis is an [open source project](LICENSE.md). Please contribute by forking this repo and issueing a pull request. The project has had notable contributions already, like reading ITPC data.\n\nYou can also contribute by [filing bugs or new features please issue](/exif-js/issues).\nOr improve the documentation. Please update this README when you do a pull request of proposed changes in base functionality.\n","_attachments":{},"homepage":"https://github.com/exif-js/exif-js","bugs":{"url":"https://github.com/exif-js/exif-js/issues"},"license":"MIT"}