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.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, Ed, biapar, Willr, Ingo, swaiba

FileDataObject different file types.

Go to End

2 Posts   865 Views

Matty Balaam

Community Member, 74 Posts

17 June 2010 at 9:30pm

I am attempting to make a module based around JPlayer (quite slowly as it goes, I'm stuck with how to pull info from the database into an array). See here for the background:

I have another issue at the moment. JPlayer can play either MP3, or OGG files and will select which is the best option itself (MP3 on some browsers relies on a Flash player, and other browsers don't play OGG files). I am wondering Is there some way of linking both MP3 and OGG files into one DataObject?


Matty Balaam

Community Member, 74 Posts

22 June 2010 at 2:21am

OK, was really easy when I just tried it, I just added a new 'File' called Ogg in the $has_one array, and then added the new fields into the popup. Don't know why I thought it would be any harder.

Great stuff.