Share This Document
Copy and Paste URL
Page
No description. Ask the publisher to add a description
5 Pages
Date Added |
03/06/2007 |
Category |
Uncategorized. |
Tags |
|
Groups |
|
Awards |
|
Copyright |
|
More info » |
|
This was quite helpful in developing a PHP-based client for a Rails-based REST service. One correction though:
When you make a POST or PUT request, the body should not be XML but rather application/x-www-form-ur lencoded encoded, for example:
obj[attr]=value&obj[a ttr2]=value2
It's only the replies from the server that are XML. This tripped me up a bit, since it was not clear in the core documentation either.
Also, my client library is available here:
http://code.google.com/p/phpactiveresource/
Hopefully that saves someone some time.
- Lux