7938 Posts in 1466 Topics by 943 members
|Go to End|
22 June 2009 at 8:11am
Where can I find clean and simple examples of how to use FileDataObjectManager with video?
I have virtually no prior knowledge of SilverStripe so it would be nice with examples that doesn't assume that the user knows how SilverStripe works as an CMS. Specifically it would be nice with an example that show how to put a video on my homepage. What I want to do in the end is to create a site where I will have a four different video galleries with about 5-6 videos each. Then I would like to be able to promote one video from any of these galleries to the homepage.
I know this is probably super simple however having only limited knowledge of PHP I can't really wrap my head around how to do this right now. The FileDataObjectManager seem like an option but as I'm not at all familiar with SilverStripe I can't seem to get the bigger picture. I did see the Youtube clip, http://www.youtube.com/watch?v=239nAqxizjA, showing the media feature of FileDataObjectManager. However I don't even know how to puzzle that together.
Thankful for any help.
22 June 2009 at 8:27am
Well, before you go any further with it, the video features of FDOM require that you have FFMPEG installed on your Linux server. To check if you do, place the line FLV::echo_ffmpeg_test(); in your _config.php. (preferably not on your live site, though)
22 June 2009 at 8:32am
I thought if I already had the files available as FLVs then it would work regardless. If that's not the case I doubt I can install it on Dreamhost or Mediatemple.
22 June 2009 at 8:50am
You can get most of the functionality with just FLV, but you can't get the thumbnailing. And you'd be surprised -- a lot of hosts have it installed already.
23 June 2009 at 7:07am
Ok. It looks like I will have access to ffmpeg on dreamhost, if not I can live without the thumbnails.
Anyways back to my original problem. How to promote a video to the homepage?
I managed to copy the code from one of your examples and make it upload and play FLV's. So I have created four pages that all have one video or more. Now I would like to create a simple way to promote any of these videos to my homepage. How would I go about to do that. Of course the nicest would be to be able to show all thumbnails for the videos but as I'm not sure I will have thumbnails a drop down list where I can select the name of the video also works.
Hope I'm making myself clear and that someone could help me out.
23 June 2009 at 7:34am
You could probably do a $has_one MyVideoClass on your HomePage object, and then manage the relationship with a HasOneDataObjectManager, right?
|Go to Top|