PHP/cURL: disable 100-continue expectation
December 29, 2008
/ Filed under: Apache, 100-continue, cURL, Twitter, API
Twitter recently changed their API to disallow requests with the 100-continue expectation included. This had an immediate effect on various third-party services using the API to post updates. View full Google Group thread here. The response coming back from the server was status 417: Expectation Failed. This has to do with the 100-continue header, which Apache displays as such:
This 100-continue status is "expected" by default when using cURL:
To turn it off this expectation in your PHP code, use this command:
I discovered this quick tip at this helpful site. You can read more about the 100 (Continue) status at w3.org.
Comments/Mentions
|
Editor Picks
Email NewsletterSubscribe to the digest newsletter to receive posts by email: Recent Comments
Advertisements
|
Beautiful, thank you.