{"action":"created","issue":{"url":"https://api.github.com/repos/summernote/summernote/issues/1198","labels_url":"https://api.github.com/repos/summernote/summernote/issues/1198/labels{/name}","comments_url":"https://api.github.com/repos/summernote/summernote/issues/1198/comments","events_url":"https://api.github.com/repos/summernote/summernote/issues/1198/events","html_url":"https://github.com/summernote/summernote/issues/1198","id":92712211,"number":1198,"title":"How to get Image data?","user":{"login":"camj256","id":6239949,"avatar_url":"https://avatars.githubusercontent.com/u/6239949?v=3","gravatar_id":"","url":"https://api.github.com/users/camj256","html_url":"https://github.com/camj256","followers_url":"https://api.github.com/users/camj256/followers","following_url":"https://api.github.com/users/camj256/following{/other_user}","gists_url":"https://api.github.com/users/camj256/gists{/gist_id}","starred_url":"https://api.github.com/users/camj256/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/camj256/subscriptions","organizations_url":"https://api.github.com/users/camj256/orgs","repos_url":"https://api.github.com/users/camj256/repos","events_url":"https://api.github.com/users/camj256/events{/privacy}","received_events_url":"https://api.github.com/users/camj256/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-02T19:11:17Z","updated_at":"2015-07-03T05:26:48Z","closed_at":"2015-07-03T05:26:48Z","body":"How do I get the raw image data to save.\r\n```\r\nonImageUpload: function(files) {\r\n            console.log(files[0]);\r\n        }\r\n```\r\n\r\ngives me:\r\n\r\n{ '0':\r\n   { name: '11267415_1601731183408003_3837764226454205111_o.jpg',\r\n     lastModifiedDate: '2015-06-25T19:55:09.269Z',\r\n     lastModified: 1435262109269,\r\n     webkitRelativePath: '',\r\n     size: 525813,\r\n     type: 'image/jpeg' },\r\n  length: 1 }\r\n\r\n\r\nI'm in node.js btw."},"comment":{"url":"https://api.github.com/repos/summernote/summernote/issues/comments/118240100","html_url":"https://github.com/summernote/summernote/issues/1198#issuecomment-118240100","issue_url":"https://api.github.com/repos/summernote/summernote/issues/1198","id":118240100,"user":{"login":"camj256","id":6239949,"avatar_url":"https://avatars.githubusercontent.com/u/6239949?v=3","gravatar_id":"","url":"https://api.github.com/users/camj256","html_url":"https://github.com/camj256","followers_url":"https://api.github.com/users/camj256/followers","following_url":"https://api.github.com/users/camj256/following{/other_user}","gists_url":"https://api.github.com/users/camj256/gists{/gist_id}","starred_url":"https://api.github.com/users/camj256/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/camj256/subscriptions","organizations_url":"https://api.github.com/users/camj256/orgs","repos_url":"https://api.github.com/users/camj256/repos","events_url":"https://api.github.com/users/camj256/events{/privacy}","received_events_url":"https://api.github.com/users/camj256/received_events","type":"User","site_admin":false},"created_at":"2015-07-03T05:26:48Z","updated_at":"2015-07-03T05:26:48Z","body":"Sorry, that was stupid. Just needed to read in the file with something like:\r\n\r\n```\r\n            var reader = new FileReader();\r\n            reader.onload = function(){\r\n                var dataURL = reader.result;\r\n                console.log(dataURL);\r\n            };\r\n            reader.readAsText(files[0], 'base64');\r\n```"}}