Archive for the 'Active Resource (REST)' category

Active Resource and Serialised columns

Friday, October 19th, 2007

Currently using serialised columns with Active Resource is broken. To serialize xml, Active Resource uses Active Support’s to_xml method which seems to have a few problems.
>> {:ruby_symbol => :sym}.to_xml
=> <?xml version="1.0" encoding="UTF-8"?><hash><ruby-symbol:sym/></hash>
What is ruby-symbol:sym I ask you! Rails obviously chokes on this xml and your post/put fails. However, serializing Active Record objects works fine:
>> User.find(:first).to_xml
=> […]

Active Resource (REST) | No comments

button_to_remote - (POST/DELETE/PUT) links without JavaScript

Saturday, September 15th, 2007

I’ve been playing around with RESTfull procedures, trying to get a link (or something that looks like one) to use the same method and url, regardless of whether JavaScript is enabled or not.
Rails has the link_to_remote, which accepts a ‘method’ option. This is all fine and dandy if you have JavaScript enabled, but, as soon […]

Active Resource (REST), Rails | 5 comments

RestResponses - Plugin for Rails Drying up RESTfull Controllers

Friday, August 10th, 2007

These last few weeks I’ve been sailing around the cornish coast and eating lots of cream teas and pasties! I’ll be back on the 25th of August, but until then, I’ve created a plugin for Rails called RestResponses:
Install: ruby script/plugin install http://rest-responses.googlecode.com/svn/trunk/rest_responses
RestResponses is a couple of useful little methods to clear up your restfull controllers, […]

Active Resource (REST), Rails | No comments

REST & Active Resource with Javascript

Monday, April 2nd, 2007

This looks interesting, and it’s good that the rails conventions for REST are becoming pretty ubiquitous.
http://giantrobots.thoughtbot.com/2007/4/2/jester-javascriptian-rest

Active Resource (REST) | No comments

AS3 Active Resource (REST) lib

Saturday, February 24th, 2007

Update: Deleting and updating records now works, take a look at the svn for examples. Auth and proper responses to invalid records still need implementing. Flash doesn’t support status codes, so I might need to use this lib.
This is referring to the post I made earlier.
I’ve started up a google code project and committed the […]

Active Resource (REST) | 2 comments

RESTful Authentication

Friday, January 12th, 2007

I said earlier that I’d do a post about Authentication and REST, so here it is. One of my motivations for doing this is getting a convention set up that Rails developers can follow that doesn’t use http basic (since the security implications of sending a username and password with every request aren’t good). The […]

Active Resource (REST), Rails | 14 comments

Active Resource for Actionscript 3

Monday, January 8th, 2007

Update here. 
With the release of Active Resource (and Rails support for REST) I foresee a lot of services popping up that conform to the Active Resource way of thinking. However, this isn’t just a Rails thing. If developers, in any language, can be encouraged to make simple REST interfaces to the apps, than life would […]

Active Resource (REST), Rails | 3 comments

Active Resource Tutorial

Tuesday, January 2nd, 2007

I’ve been messing around with Active Resource a bit lately (to do with aireo) and I though I’d write a tutorial on it (giving the sparseness of documentation at the moment).
This tutorial expects you to have the restfull conversion methods in application.rb (as explained in the previous post), and a model called “post” with attributes […]

Active Resource (REST), Rails | 6 comments

Gems of knowledge regarding Rest on Rails

Monday, January 1st, 2007

I’d just like to share with you my method of generating the same structure to data for restful responses, in the hope that this helper method will get added to to_json and to_yaml (as it is already for to_xml). Currently, if you convert a model into json or yaml, it isn’t in the same format […]

Active Resource (REST), Rails | 2 comments

You are currently browsing the Eribium archives for the 'Active Resource (REST)' category.

Pages

Meta