fzaninotto / screenshot-as-a-service

Website screenshot service powered by node.js and phantomjs
1.1k stars 243 forks source link

Enable CORS #37

Closed cburgmer closed 11 years ago

cburgmer commented 11 years ago

Adding CORS support (http://www.html5rocks.com/en/tutorials/cors/).

This allows browsers to directly load images from the server via a XMLHttpRequest.

Disabled by default. Can be turned on by setting

server:
  useCors: true

The two headers do the following

fzaninotto commented 11 years ago

Thanks!