PUT and POST getting 405 Method Not Allowed Error for Restful Web Services

后端 未结 6 2298
无人及你
无人及你 2020-12-09 18:32

I am trying to set up a simple Restful Web-Service which returns either JSON or XML according to the Accept header. I am using Spring, Maven and WebLogic Server. I took the

6条回答
  •  一生所求
    2020-12-09 19:17

    I'm not sure if I am correct, but from the request header that you post:

    Request headers

    Accept: Application/json

    Origin: chrome-extension://hgmloofddffdnphfgcellkdfbfbjeloo

    User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.76 Safari/537.36

    Content-Type: application/x-www-form-urlencoded

    Accept-Encoding: gzip,deflate,sdch Accept-Language: en-US,en;q=0.8

    it seems like you didn't config your request body to JSON type.

提交回复
热议问题