{"action":"created","issue":{"url":"https://api.github.com/repos/deweyapp/dewey/issues/131","labels_url":"https://api.github.com/repos/deweyapp/dewey/issues/131/labels{/name}","comments_url":"https://api.github.com/repos/deweyapp/dewey/issues/131/comments","events_url":"https://api.github.com/repos/deweyapp/dewey/issues/131/events","html_url":"https://github.com/deweyapp/dewey/issues/131","id":60179679,"number":131,"title":"Screenshots: SOLUTION.","user":{"login":"Shakarhaba","id":1680143,"avatar_url":"https://avatars.githubusercontent.com/u/1680143?v=3","gravatar_id":"","url":"https://api.github.com/users/Shakarhaba","html_url":"https://github.com/Shakarhaba","followers_url":"https://api.github.com/users/Shakarhaba/followers","following_url":"https://api.github.com/users/Shakarhaba/following{/other_user}","gists_url":"https://api.github.com/users/Shakarhaba/gists{/gist_id}","starred_url":"https://api.github.com/users/Shakarhaba/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shakarhaba/subscriptions","organizations_url":"https://api.github.com/users/Shakarhaba/orgs","repos_url":"https://api.github.com/users/Shakarhaba/repos","events_url":"https://api.github.com/users/Shakarhaba/events{/privacy}","received_events_url":"https://api.github.com/users/Shakarhaba/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-03-07T00:33:50Z","updated_at":"2015-03-11T14:06:11Z","closed_at":null,"body":"The problem\r\n----------------\r\nThe problem is that the screenshots provider is no longer generating and returning the screenshots.\r\n\r\nThe solution\r\n----------------\r\nWhat I did to get it working again is simple, run my own screenshoot generator.\r\n\r\n- Install wkhtmltopdf http://wkhtmltopdf.org/downloads.html\r\n- Install Apache + PHP\r\n       - Windows: Just install WAMP\r\n       - Ubuntu: apt-get install apache2, php5\r\n- Enable headers apache module (a2enmod headers, in wamp use the menu from the system tray)\r\n- Install/Enable curl if you want to check if the bookmark no longer exists\r\n- In the www directory create a .htaccess file and folder called thumbnails\r\n \r\n>**.htaccess content**\r\n<pre>Header set Access-Control-Allow-Origin \"*\"\r\nHeader set Access-Control-Allow-Headers \"Cache-Control, Pragma, Origin, Authorization, Content-Type, X-Requested-With\"\r\nHeader set Access-Control-Allow-Methods \"GET, PUT, POST\"</pre>\r\n\r\n5) Then download this gist: https://gist.github.com/Shakarhaba/2b9c6a9c0c3440d71951 and place it in www, call it index.php (you can rename it to whatever you want but you will have to edit updateBackground.js accordingly).\r\n\r\n6) Edit the options if needed (You will have to set the path to the wkhtmltoimage binary at least).\r\n\r\n7) Edit dewey/js/directive/updateBackground.js https://github.com/deweyapp/dewey/blob/master/js/directives/updateBackground.js\r\n\r\n>**Point to localhost as the screenshot provider, and pass the url as a HTTP Post variable**\r\n<pre>\r\n37 - url: 'http://api.page2images.com/restfullink?p2i_url=' +\r\n38 - encodeURIComponent(url) +\r\n39 - &p2i_device=6&p2i_size=400x150&p2i_screen=1024x768&p2i_imageformat=jpg&p2i_wait=0&p2i_key=7cd903b37d087238',\r\n37 + url: 'http://localhost',\r\n38 + data: {url: url},\r\n</pre>\r\n\r\nVoilà, now you generate your own screenshots and you are no longer dependent of a third party screenshot providers that might leave you hanging in the near future.\r\n\r\nAs this solution works with apache + php you can place this on a web server on a NAS or a computer that it's always on, set up some DDNS and access your screenshots from any computer/device.\r\n\r\nI love using Dewey, but I **NEED** the visual details from the screenshots so I had to edit it right away to get it working, at least until a new Screenshot provider is implemented."},"comment":{"url":"https://api.github.com/repos/deweyapp/dewey/issues/comments/78268758","html_url":"https://github.com/deweyapp/dewey/issues/131#issuecomment-78268758","issue_url":"https://api.github.com/repos/deweyapp/dewey/issues/131","id":78268758,"user":{"login":"apple1314518","id":10636785,"avatar_url":"https://avatars.githubusercontent.com/u/10636785?v=3","gravatar_id":"","url":"https://api.github.com/users/apple1314518","html_url":"https://github.com/apple1314518","followers_url":"https://api.github.com/users/apple1314518/followers","following_url":"https://api.github.com/users/apple1314518/following{/other_user}","gists_url":"https://api.github.com/users/apple1314518/gists{/gist_id}","starred_url":"https://api.github.com/users/apple1314518/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apple1314518/subscriptions","organizations_url":"https://api.github.com/users/apple1314518/orgs","repos_url":"https://api.github.com/users/apple1314518/repos","events_url":"https://api.github.com/users/apple1314518/events{/privacy}","received_events_url":"https://api.github.com/users/apple1314518/received_events","type":"User","site_admin":false},"created_at":"2015-03-11T14:06:10Z","updated_at":"2015-03-11T14:06:10Z","body":"if your installation process involves me downloading a program that is not\nlisted in the installation process as one of 7 involved steps than it is\nanything but easy.\n\n2015-03-11 10:03 GMT-04:00 Shakarhaba <notifications@github.com>:\n\n> Easy install? http://www.mamp.info/en/\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/deweyapp/dewey/issues/131#issuecomment-78268346>.\n>\n"}}