Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Archive

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

SS backend for Flash site: is this possible?


Reply

6 Posts   3027 Views

Avatar
vcmusic42

5 June 2008 at 9:44am (Last edited: 5 June 2008 9:46am), Community Member, 22 Posts

Simple question...I just need to know if I'm on crack or totally off the mark with this one. I ran across a forum post (on another site) where someone mentioned they were trying to implement a Silverstripe-run site that displayed in Flash. I don't just mean a Flash include, I mean pretty much the whole thing in Flash.

(yes, I realize many of us still hate Flash for its accessibility & SEO issues and other grievances, but I'm just curious).

I have a soft spot in my heart for SS and have been very impressed with its flexibility over the past few months, but since this is a site for a musician, I'm struggling with how to present the creative content, and now I'm torn between the two (Flash vs. non-Flash).

I was assuming the best I could do regarding updating dynamic content in Flash would be a text file/xml. But could SS somehow be implemented in this as well?

Any feedback from those "in the know" is greatly appreciated.

Avatar
Ingo

6 June 2008 at 9:31am (Last edited: 6 June 2008 9:32am), Forum Moderator, 801 Posts

Flash-driven frontends are generally not a problem for Silverstripe, see http://www.californiawomen.org/ and http://thelowdown.co.nz/ for good examples.

Say you want to output all children for a specific page as XML for parsing in flash (in Page_Controller):

function childrenasxml() {
$pages = $this->dataRecord->Children();
return $this->customise(array('Pages'=>$pages))->renderWith('Pages_xml');
}

the Pages_xml.ss template:

<pages>
<% control Pages %>
<page>
<title>$Title</title>
</page>
<% end_control %>
</pages>

call via mydomain.com/<mypageurl>/childrenasxml

Avatar
Sean

7 June 2008 at 2:04pm (Last edited: 7 June 2008 2:04pm), Forum Moderator, 921 Posts

You might want to check out AMFPHP for this one

http://www.amfphp.org/

It allows flash to get PHP objects and classes, very handy!

Avatar
ChevronX

8 June 2008 at 12:29am Community Member, 6 Posts

*rubs hands Silverlight*

Avatar
vcmusic42

8 June 2008 at 6:48pm Community Member, 22 Posts

Thanks for the replies...I'm very excited about the prospect of still being able to use SS for this.

I checked out AMFPHP and downloaded some examples...but just so I'm clear, would AMFPHP be used to help SS and Flash communicate, or is it a way of bypassing Silverstripe?

I'd like to figure this out, but I'm not a coder. I'm considering taking a course in PHP and I know some online tutorials in MySQL and Actionscript would be useful, but even with all that, I'll still be lightyears behind everyone else. I'd be willing to invest a few weeks delving into this new material, but many of the tutorials linked from the AMFPHP site were outdated, and I wouldn't begin to know how to take it from the "Hello World" step to the type of event lists and news I can do in Silverstripe.

Is this integration of AMFPHP, SS and Flash something a freelancer would be able to tackle? (Through mailing lists, Scriptlance, etc.).

Avatar
stuntmax

16 June 2008 at 3:46am (Last edited: 16 June 2008 4:25am), Community Member, 21 Posts

I would know how can I use this video player on Silverstripe?

http://www.jeroenwijering.com/?page=wizard&example=13

Thanx