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've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

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

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

i-lateral's silverstripe-carousel


Go to End


4 Posts   819 Views

Avatar
cdwilliams

Community Member, 8 Posts

26 June 2015 at 10:19am

Hello,

I am using i-lateral's silverstripe-carousel, but I want every image of the carousel to be linked to a page on the website. What is the best way to achieve this?

Thanks.

Avatar
Pyromanik

Community Member, 419 Posts

26 June 2015 at 10:57am

Edited: 26/06/2015 10:58am

By reading the instructions of course!

https://github.com/i-lateral/silverstripe-carousel

Once installed, you must add the template variable $CarouselSlides to any templates you require a carousel to appear on.

Then, you can setup a carousel by logging into the admin interface and editing the page you want to add a carousel to.

Then click the "Settings" tab, and tick the "add carousel" checkbox.

Once this is done (and you have saved) you will see a width and height overwrite appear (allowing you to change the size of your carousel).

Once you have finished configuring, you can go back to editing you page, and a "carousel" tab should have appeared in the right hand site of the editing pane.

Avatar
cdwilliams

Community Member, 8 Posts

26 June 2015 at 11:12am

Edited: 26/06/2015 11:13am

Yes. I have the carousel up and running. All is well except that I want the images to be linked to pages on my site. For now, the images are static, so that nothing happens when a visitor clicks on them. Any ideas? The instructions do not cover how to do this.

Avatar
Pyromanik

Community Member, 419 Posts

30 June 2015 at 9:25pm

Yep, check out the docs on DataExtension.
Create one that adds a has_one to a page (or a textbox for manual entry of a uri, or some kind of combination) and the form fields for filling it in, then apply it to CarouselSlide.
dev/build?flush
???
profit.

:)