Author Topic: CORS 設定教學文件 (Ajax 存取跨網站資源)  (Read 5485 times)

admin

  • Administrator
  • *****
  • Posts: 0
    • View Profile
CORS 設定教學文件 (Ajax 存取跨網站資源)
« on: April 30, 2012, 01:57:36 AM »
enable cross-origin resource sharing
http://enable-cors.org/

HTTP access control (CORS)
https://developer.mozilla.org/en/HTTP_access_control


Apache 設定樣本
.htaccess 檔案內加入下列的設定参數 :

<IfModule mod_headers.c>
    Header set Access-Control-Allow-Origin "*"
    Header set Access-Control-Allow-Headers "Origin, X-Requested-With, Content-Type, Accept"
</IfModule>
« Last Edit: May 01, 2012, 03:07:09 AM by Roy Chan »