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.

Customising the CMS

Image Rotator For SilverStripe Application


Go to End
Reply

9 Posts   3592 Views

Avatar
erhan

30 January 2009 at 1:22pm Community Member, 6 Posts

Hi,

An article about adding image rotator functionality to the ss site.

http://erhanabay.com/2009/01/30/image-rotator-for-your-silverstripe-application/

Comments and suggestions are welcome...

Avatar
Fuzz10

30 January 2009 at 9:45pm Community Member, 787 Posts

Cool writeup , would you mind creating a recipe in the Silverstripe Wiki as well ? That way , all info will be centralized.

See http://doc.silverstripe.com/doku.php?id=recipes:start&s=recipes

Avatar
Taffy

30 January 2009 at 10:47pm Community Member, 119 Posts

Nice one. I'm going to use the JW player in an up coming project and this will be a great help since i'm a SS newbie.

Avatar
erhan

31 January 2009 at 2:33am Community Member, 6 Posts

Thank you.

I am going to add it as soon as I have time.

Avatar
UncleCheese

31 January 2009 at 5:06am 4085 Posts

Very nicely architected, though I'm not sure that a flash object is necessary. I usually do this with a few lines of javascript, as seen here:

http://www.blackriverdesign.com

Avatar
erhan

31 January 2009 at 5:25am Community Member, 6 Posts

Different approach, nice job!

But flash rotator can handle swf files as well. ;)

Avatar
freewolny

31 January 2009 at 6:05am Community Member, 12 Posts

another example with javascript

[url=http://malsup.com/jquery/cycle/]JQuery Cycle Plugin[/url]

Avatar
Trym

11 March 2009 at 5:44pm Community Member, 18 Posts

Hi UncleCheese

I have in Page.php created a function
function FrontPageRotator() {
   return DataObject::get("Image", "`ParentID` = 31");
}

And in Page.ss the following template code
<% if frontPageRotator %>
<% control frontPageRotator %>
$Link<br />
<% end_control %>
<% end_if %>

I wanted to have $Image.setWidth(140) instead of $Link, but I dont seem to be able to refer to $Image.
Can you help?

Thanks in advance.

Best regards Trym

Go to Top