Today you encounter Request Failed:method not allowed (405). Error, and I hereby turn over the Internet.

Source: Internet
Author: User

Q1:405 Request error encountered. Tips:
Nslocalizeddescription=request Failed:method not allowed (405).
Solution: 405 The request method is not allowed. You should check that the request method is correct and the page should use a GET request or a POST request. For example, while requesting a microblog access_token, it does not need to send data but this page requires a POST request.


Q2: HTTP request with Afnetwork encountered the following error message:
Nslocalizeddescription=request failed:unacceptable
Content-type:text/plain.
Solution: The error message here is because the Afhttprequestoperationmanager default HTTP request header does not contain the Text/plain format. should use
Manager.responseSerializer.acceptableContentTypes = [Manager.responseSerializer.acceptableContentTypes setbyaddingobject:@ "Text/plain"]; manually added. Of course, there may also be text/html types. The solution is similarly added manually.

Turn from:

http://blog.csdn.net/cnlf14/article/details/44997111

Today you encounter Request Failed:method not allowed (405). Error, and I hereby turn over the Internet.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.