Topic: pulling RoR content into flash.

i am in the process of upgrading a site from php to RoR. many parts of the site were in flash and pulled external content from php files. the php files communicated with the database to get the dynamic content and flash would take it and put it all in a dynamic text box.

i tried doing the same thing with RoR, and for some reason, it never works when i tried to load a file like it's local. i have to put http://www.example.site/data_info instead of just /data_info. on top of that, the whole thing only works if i have a www in the url for the page that contains my flash file. so i would have to have http://www.example.site/ and not http://example.site.

if i had to guess at what's going on, i think having the full url in there forces it to process whatever ruby spits out and calling the files like they are local tries to find a raw file before being processed by ruby. this is mere speculation though and i would like to hear from anyone trying the same thing to see if there is something i am doing wrong or what.

i realize that the way we're pulling content into our flash is an older way of doing things, but at this point, it'll be easier to get this working than to rewrite all of our actionscript.

Re: pulling RoR content into flash.

i'd love to see some sort of ror/flash resource, although i wonder if it clashes too much with the web 2.0 association.  but when php and flash were first becoming friends there were many resources out there.  I havent seen much about RoR and flash at all...so i would love to know more when someone comes up with something

sorry i dont have an answer, i'm just curious too.

...

Re: pulling RoR content into flash.

I don't really have any answer either (sorry!), but 'web 2.0' means a lot of things to a lot of people, but I think your point was that may Flash is too cool for Rails...  I don't think so.  While I definitely hope that most all-flash pages go the way of the do-do, Flash does still have some valid applications (especially since if you want to promote a service with a MySpace widget, you need to use Flash).  Making it play nice with your RoR code could be beneficial to a lot of people.

After a quick Google search, something that may be helpful:

http://rails.techno-weenie.net/question … _for_flash

Josh Catone helps run this place
Rails Forum - Rails Jobs

Re: pulling RoR content into flash.

Do you know the Framework Adobe Flex to create RIAs based on Flash

Concretely the Flex server side engine is in Java (well integrated in many J2EE servers)
When you develop UI you use a derived XML format (MXML)
You write your classes in Action Script (some developers don't like because it is a proprietary language..derived from ECMAScript)
You drop your files in a web app on your server: you configure a Filter in your web.xml file to handle .mxml files : The Filter generates the binary, which is SWF (Flash format).

You can, in development phase, precompile your MXML files to SWF: doing this, you can imagine deploying your appli in a non-J2EE environment...
An Adobe developer working on Flex, has done this with Rails; here is the link:
http://coenraets.com/tutorials/flexonra … rails.html

Flex is a commercial product, but the Flex 2 SDK can be downloaded for free : http://www.adobe.com/products/flex/ (bottom of the page)

An open source solution like Flex is Open Laszlo: http://www.openlaszlo.org/
The script language used for the business logic in Laszlo is JavaScript.

But i haven't seen any resources about Open Laszlo UI plugged on top of Rails server-side scripts.

Laurent Bois
MacBook 2GHz Core Duo, 2GB RAM, 160GB HDD
my blog
my del.icio.us

Re: pulling RoR content into flash.

yeah, i've looked at flex. very cool stuff! i'm working on mac right now though so i'm waiting for their flex developer for mac computers which is supposed to come out sometime this year.

i hadn't heard of lazlo though. i just went to the site to check it out, and i'm pretty impressed. i did a google search for it with RoR and found this site: http://laszloonrails.com/mediawiki-1.6. … =Main_Page

i'll prlly check it out here soon.

Re: pulling RoR content into flash.

Thanks for this link...i haven't googled laszlo with rails

For Flex, last year an Eclipse plugin, code named Zorn , has be announced. No news today
http://radar.oreilly.com/archives/2005/ … crome.html

Laurent Bois
MacBook 2GHz Core Duo, 2GB RAM, 160GB HDD
my blog
my del.icio.us

Re: pulling RoR content into flash.

I just posted this link in another thread, and I knew there was somewhere else I wanted to post it... but I couldn't remember where. wink

http://blog.vixiom.com/2006/08/23/flash … -tutorial/

This tutorial goes over sending data from rails to flash.

Josh Catone helps run this place
Rails Forum - Rails Jobs