Jump to:

23486 Posts in 18995 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » Simple Javascript Image/Banner Rotator

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Page: 1 2
Go to End
Author Topic: 2751 Views
  • Pix
    Avatar
    Community Member
    135 Posts

    Simple Javascript Image/Banner Rotator Link to this post

    Hi!

    I'm sure there must be something like this, or a SilverStripe tutorial, but I can't find it. What I would like to do is have a custom page that has a Javascript image/banner rotator. I am very comfortable with extending a basic site as outlined in the SS tutorial, but this one is has got me stumped. For instance, I can see how you add a photo or banner to a custom page, but how would you add multiple photos and then call one of the various javascript image galleries out there to rotate through them? Can anyone point me in the right direction? Perhaps there is a tutorial or module for this already?

    Thank you!

  • Felicitas
    Avatar
    Community Member
    16 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    Hi,

    I made a simple imagerotator module for my work to rotate logo's on any page they want. It lets you create a RotatorPage where you can add logo's (or other images). The actual RotatorPage with the rotating images is invisible in the menu, but you can show the rotating images in an iframe in any other page. See the README file in this module.

  • Pix
    Avatar
    Community Member
    135 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    Alright! Thanks for sharing this I will give it a go!

  • arthurdent
    Avatar
    Community Member
    163 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    Just gave this module a go but got a Fatal Error first time round...

    Fatal error: Class 'DataObjectManager' not found in /User/Sites/dev/imagerotator/code/RotatorPage.php on line 35

    Any clues?

  • Howard
    Avatar
    Community Member
    215 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    arthurdent, have you got the DataObjectManager module installed? Looks like it needs to be.

    Felicitas you might want to make a note of that in the README or else have the module fall back to a ComplexTableField if they don't have DOM installed.

  • arthurdent
    Avatar
    Community Member
    163 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    Thanks for the pointer Howard! You've helped me out a few times lately which is much appreciated. I'm a graphic designer by trade, I can also do HTML and CSS and incorporate theim int a SilverStripe theme but PHP is still a little outside my scope!!

    thanks again!

  • Howard
    Avatar
    Community Member
    215 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    No worries glad I could help

    There's no need to get heavily into the PHP but once you realise how easy it can be to add extra fields to pages on your site then they become really useful and addictive.

  • arthurdent
    Avatar
    Community Member
    163 Posts

    Re: Simple Javascript Image/Banner Rotator Link to this post

    Still not out of the woods yet...

    Things got so heavy I eventually had to trash my test install and DB and start again! Once up and running I loaded DataObjectManager (dev/build/) and them Imagerotator (dev/build/). It was all looking pretty froody until I went to set up the Rotator page...

    Then it had a Javascript error, threw a bit of a hissyfit and went into a spin (1 error, 2 errors, etc..)

    Any more words of advice -- or should I give up and do this in Flash?!

    2751 Views
Page: 1 2
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.