[Catalyst] DELETE through REST and Jemplate

Alejandro Imass alejandro.imass at gmail.com
Mon Apr 13 05:48:30 GMT 2009


On Thu, Apr 2, 2009 at 5:51 PM, Lee Aylward <lee at laylward.com> wrote:
> On Mon, Mar 30, 2009 at 04:24:42PM +0200, Emmanuel Quevillon wrote:
>> Hi,
>>
>> I am playing with REST and Jemplate from the great Tuts from JRock's
>> book.
[...]

> As has already been mentioned, you'll have to use a seperate javascript
> library to make your requests, since Jemplate only supports GET. Be
> careful when choosing a javascript library. I recently tried to use
>

Not true: http://p2ee.svn.sourceforge.net/viewvc/p2ee/inventory/trunk/inventory/root/src/w2app/p2ee.js?revision=1&view=markup



 prototype.js to make some PUT and DELETE requests. After investigating,
> I discovered that prototype.js does not support some HTTP methods, and
> converts them to a POST with an added "_method" parameter that matches
> the method you wanted to use. I believe they do this because at some
> point not all browsers supported alternative HTTP methods over
> XMLHTTPRequest.

Prototype's REST sucks. JQuery full HTTP methods works fine with
Firefox. It's usually a limitation of the browser's ability to use
other methods, not the JS lib's. Anyway, we use full HTTP with JQuery
no problem.

>
> --
> Lee Aylward
>
> _______________________________________________
> List: Catalyst at lists.scsys.co.uk
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
> Dev site: http://dev.catalyst.perl.org/
>



More information about the Catalyst mailing list