views:

150

answers:

2

Hi guys,

i am looking into the possibilities of doing some work for a client on Flex with a Rails backend.

It ain't rocket science however i was wondering if anyone out there had some experiences with these two AWESOME technologies?

Thanks in advance....

+3  A: 

Peter Armstrong has written an excellent book called Flexible Rails, and has also created a Flex/Rails framework called Ruboss. I recommend you check out both of these resources.

Mike Sickler
I got the book but thanks for pointing me to the framework...
featureBlend
A: 

I have developed a few application using Flex and Rails. The easiest way is just to use the as3corelib (http://code.google.com/p/as3corelib/) and use standard JSON objects. You can play around with the AMF serializers, but none of them are production ready (they are written in ruby and not C).

The biggest thing you need to make sure of is if you are creating resources from Flex you need to send the authenticity key from flex. I do this by writing a helper to output it to a view:

<script language="Javascript">
    function getAuthKey() { return "<%= form_authenticity_token %>"; }
</script>

Then use ExternalInterface to call it inside Flex.

ExternalInterface.call('getAuthKey')
camwest