[Catalyst] Catalyst::*::REST and Javascript
Jonathan Rockway
jon at jrock.us
Tue Aug 19 19:26:30 BST 2008
* On Fri, Aug 15 2008, Patrick Donelan wrote:
> Hi Robert,
>
>
> Whereas ExtJS seems to be of form:
>
> userResource = new Resource('http://example.com/users?id=001')
>
>
> ExtJS can send any sort of HTTP request you like - it doesn't really care how
> RESTful your URLs are. Like all Ajax toolkits the connectivity portion of the
> library is just a glorified wrapper around the browser's XHR object.
FWIW, this style URL is not "not RESTful". It's perfectly RESTful -- it
refers to exactly one noun, and you can mutate it with HTTP methods
(presumably). That's REST.
If you wanted to make it non-RESTful, then you would do things like:
GET http://example.com/users?id=001&operation=delete&archive=0
or
GET http://example.com/users/001?operation=delete&archive=0
That's RPC, not REST. But as you can see, the URL scheme is irrelevant
when determining what is and is not RESTful.
Regards,
Jonathan Rockway
--
print just => another => perl => hacker => if $,=$"
More information about the Catalyst
mailing list