{"action":"created","issue":{"url":"https://api.github.com/repos/devgeeks/Canvas2ImagePlugin/issues/49","labels_url":"https://api.github.com/repos/devgeeks/Canvas2ImagePlugin/issues/49/labels{/name}","comments_url":"https://api.github.com/repos/devgeeks/Canvas2ImagePlugin/issues/49/comments","events_url":"https://api.github.com/repos/devgeeks/Canvas2ImagePlugin/issues/49/events","html_url":"https://github.com/devgeeks/Canvas2ImagePlugin/issues/49","id":86174178,"number":49,"title":"unable to save in IOS -- Security Error 18","user":{"login":"arulapj","id":822907,"avatar_url":"https://avatars.githubusercontent.com/u/822907?v=3","gravatar_id":"","url":"https://api.github.com/users/arulapj","html_url":"https://github.com/arulapj","followers_url":"https://api.github.com/users/arulapj/followers","following_url":"https://api.github.com/users/arulapj/following{/other_user}","gists_url":"https://api.github.com/users/arulapj/gists{/gist_id}","starred_url":"https://api.github.com/users/arulapj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/arulapj/subscriptions","organizations_url":"https://api.github.com/users/arulapj/orgs","repos_url":"https://api.github.com/users/arulapj/repos","events_url":"https://api.github.com/users/arulapj/events{/privacy}","received_events_url":"https://api.github.com/users/arulapj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-08T13:18:59Z","updated_at":"2015-07-27T13:28:49Z","closed_at":null,"body":"Hi,\r\n\r\ntrying to use this plugin for ios, its working in android but not in ios, please note i am using phonegap build to compile ipa\r\n\r\ncode \r\n\r\nindex.html\r\n     <canvas id=\"myCanvas\" width=\"165px\" height=\"145px\"></canvas>\r\n\r\nscript.js\r\n[code]\r\n\tfunction uploadImage(rul) {\r\n\t\t\tvar canvas = document.getElementById(\"myCanvas\");\r\n\t\t\tvar context = canvas.getContext(\"2d\");\t\r\n\t\t\tvar imageObj = new Image();\r\n\t\t\timageObj.src = rul;\t\r\n\t\t\timageObj.onload = function () {\r\n\t\t\t\ttry{\r\n\t\t\t\t\tcanvas.width = imageObj.width;\r\n\t\t\t\t\tcanvas.height = imageObj.height;\r\n\t\t\t\t\tcontext.drawImage(imageObj, 0, 0);\r\n\t\t\t\t\t\twindow.canvas2ImagePlugin.saveImageDataToLibrary(\r\n\t\t\t\t\t\tfunction(msg){\r\n\t\t\t\t\t\t\talert(JSON.stringify(msg));\r\n\t\t\t\t\t\t},\r\n\t\t\t\t\t\tfunction(err){\r\n\t\t\t\t\t\t   alert(JSON.stringify(err));\r\n\t\t\t\t\t\t},\r\n\t\t\t\t\t\tdocument.getElementById('myCanvas')\r\n\t\t\t\t\t);\r\n\t\t\t\t}catch(e){alert(\"ERROR:\"+JSON.stringify(e));}\r\n\t\t\t};\r\n\t\t}\t\t\r\n\t\tuploadImage(\"http://icdn.indiaglitz.com/hindi/gallery/Actress/PriyankaChopra/Priyanka_Chopra_8615_218.jpg\");\r\n\r\n[/code]\r\n\r\nconfig.xml\r\n\r\n<gap:plugin name=\"org.devgeeks.canvas2imageplugin\" version=\"0.6.0\" source=\"plugins.cordova.io\" />\r\n\r\ni am getting following error when excuted \r\n{\"code\":18,\"name\":\"SecurityError\", \"message\":\"SecurityError: DOM Exception 18\",\"line\":22,\"column\":45,\"sourceURL\":\"file:///private/var/mobile/Containers/Data..../www/plugins/../Canvas2ImagePlugin.js\"}\r\n\r\nthe same thing worked for android"},"comment":{"url":"https://api.github.com/repos/devgeeks/Canvas2ImagePlugin/issues/comments/125204907","html_url":"https://github.com/devgeeks/Canvas2ImagePlugin/issues/49#issuecomment-125204907","issue_url":"https://api.github.com/repos/devgeeks/Canvas2ImagePlugin/issues/49","id":125204907,"user":{"login":"EdwinRikkers","id":2063535,"avatar_url":"https://avatars.githubusercontent.com/u/2063535?v=3","gravatar_id":"","url":"https://api.github.com/users/EdwinRikkers","html_url":"https://github.com/EdwinRikkers","followers_url":"https://api.github.com/users/EdwinRikkers/followers","following_url":"https://api.github.com/users/EdwinRikkers/following{/other_user}","gists_url":"https://api.github.com/users/EdwinRikkers/gists{/gist_id}","starred_url":"https://api.github.com/users/EdwinRikkers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/EdwinRikkers/subscriptions","organizations_url":"https://api.github.com/users/EdwinRikkers/orgs","repos_url":"https://api.github.com/users/EdwinRikkers/repos","events_url":"https://api.github.com/users/EdwinRikkers/events{/privacy}","received_events_url":"https://api.github.com/users/EdwinRikkers/received_events","type":"User","site_admin":false},"created_at":"2015-07-27T13:28:49Z","updated_at":"2015-07-27T13:28:49Z","body":"+1 for this issue... any known workaround for this ????"}}