Pg lang
Web Request
Header 名稱 設定值 Access-Control-Allow-Origin * Access-Control-Allow-Methods POST, GET, OPTIONS, PUT, DELETE,… Access-Control-Allow-Headers Accept, Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization var w http.ResponseWriter w.Header().Set("Access-Control-Allow-Origin", "*") w.Header().Set("Access-Control-Allow-Methods", "POST, GET, OPTIONS, PUT, DELETE") w.Header().Set("Access-Control-Allow-Headers", "Accept, Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization") Content-Typ
Pg lang
Curl教學
下載&安裝 請參考: 套件安裝-常用安裝項目-curl 指令 curl --help Usage: curl [options…] 選項 語法範例 -v, –verbose 可以顯示更多
Pg lang
Web相關
網址的意涵 以 https://example.org:8080/foo/bar?q=baz#bang 為例 Name Desc href https://example.org:8080/foo/bar?q=baz#bang origin https://example.org:8080 protocol https: (http, ftp, …) host example.org:8080 hostname example.org port 8080 pathname /foo/bar search ?q=baz hash bang 這些東西可以透過Location去取