Troubleshooting of HTTP errors: Difference between revisions

From LemonWiki共筆
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 5: Line 5:
== 404 File Not Found ==
== 404 File Not Found ==
[[404 Not Found | 找不到網頁的可能解決方法]]
[[404 Not Found | 找不到網頁的可能解決方法]]
== 405 Method Not Allowed Error ==
解決方法:檢查存取的文件或資源支援呼叫使用的 HTTP protocol <ref>[https://dotblogs.com.tw/cotton/2018/03/01/132336 使用Http Post呼叫api卻收到405 method not allowed | 攻城獅的學習筆記 - 點部落]</ref>,例如限制使用 POST ,卻使用 GET 存取。


== 415 Unsupported Media Type ==
== 415 Unsupported Media Type ==
Line 22: Line 25:
* [https://httpstatusdogs.com/ HTTP Status Dogs]
* [https://httpstatusdogs.com/ HTTP Status Dogs]


References
<references />


{{Template:Troubleshooting}}
{{Template:Troubleshooting}}


[[Category:Programming]]
[[Category:Programming]]

Revision as of 22:57, 31 January 2022


icon_scale_pencil.png This article "Troubleshooting of HTTP errors" is still being written. If there are any incomplete parts, you are welcome to directly edit them. 這篇文章「Troubleshooting of HTTP errors」內容還在撰寫中,如果有不完整的部分,歡迎你直接動手修改


HTTP status code

404 File Not Found

找不到網頁的可能解決方法

405 Method Not Allowed Error

解決方法:檢查存取的文件或資源支援呼叫使用的 HTTP protocol [1],例如限制使用 POST ,卻使用 GET 存取。

415 Unsupported Media Type

解決方法:「於請求中設置的 Content-TypeContent-Encoding 或對資料的直接訪問」。參考資料:415 Unsupported Media Type - HTTP | MDN

例如:RESTful API 遇到該錯誤,可能解決方式是 HTTP Headers 加入

Content-Type: application/json
200.jpg
HTTP Cats

Related websites

References


Troubleshooting of ...

Template