Home - Your one stop SilverStripe learning resource
- Show all
- Site Tree
- Site of the Month
- Model Admin
- SilverStripe 3
4 October 2010 | | | Supports v2.4, v2.3Tweet
In this two part tutorial, I am going to show you how to display DataObjects as if they were pages. This is often very useful for times when you have lots of items that don't warrant full site tree objects, but do need to be displayed on their own on the site. In this first part displaying Staff Members we are going to keep it simple, using a Data Object Manager to manage our Staff Members and referring to their ID in the URL. Later in part 2, we will see how to use ModelAdmin to manage a Search Engine friendly product catalogue.Continue reading...
3 May 2009 | | | Supports v2.4, v2.3Tweet
In this tutorial we are going to create a very simple contact form, like those commonly seen on most contact-us pages. This is a great introduction to SilverStripe forms for those new to the Subject and should also provide enough functionality for most people to use straight out of the box.Continue reading...
20 December 2010 | |Tweet
These days many sites require users to register to get full functionality (SSbits included!). This is something that although not avaiable out of the box in SilverStripe is quite strait forward and a great way to gain a better understanding of both the Member and Form systems. In this tutorial we are going to create a simple registration form and a page for users to then edit their details.Continue reading...
28 April 2010 | | | Supports v2.4Tweet
SilverStripe 2.4 has introduced shortcodes to the CMS editor. Simply, the CMS user can now add short BBCode style code to the editor area and it can then be replaced using a predefined function. For example [link id=23] could be replaced by the link to Page with an ID of 23. In fact that is exactly how internal links created in the links sidebar work in 2.4, preventing them from breaking when URLs change.Continue reading...
TutorialsControllers Instead of Pages
25 January 2011 | | | Supports v2.4, v2.3Tweet
SilverStripe is great for working with Pages in the CMS. But what if you need functionality without the need for content or all the "data fluff," like in Aram's tutorial about user registration and profile editing. Well, believe it or not, SilverStripe is a pretty solid MVC platform, even if you're working outside of the page data objects. It took me a while to understand how to implement true-ish MVC in SilverStripe, so I thought I'd take the opportunity to share.Continue reading...
TutorialsPaginating a filtered DataObjectSet
25 October 2010 | | | Supports v2.4Tweet
If you have ever tried to paginate a DataObjectSet that has been customised since fetching it from the database you will have descovered that it simply doesn't work. This short tutorial provides some great code to resolve this problem and paginate to your hearts content!Continue reading...
28 June 2009 | | | Supports v2.4, v2.3Tweet
When you have a number of pages which follow on from one another you may find that asking a user to return to an index or select the next item from a side menu each time they want to progress is cumbersome. In this situation having previous and next buttons at the bottom of a page becomes very useful. In this snippet we'll add these buttons and also a counter to show the current page we are on and the total number of pages.Continue reading...
TutorialsEmbed flash content using SWFObject
3 December 2009 | | | Supports v2.4, v2.3Tweet
There are numerous ways to embed flash content into your SilverStripe Website. A commonly used and very flexible method to embed flash is provided by the SWFObject script. In this snippet I'll show you how to create a custom FlashPage that will contain flash content, embedded using SWFObject.Continue reading...
TutorialsUsing jQuery for form validation
13 November 2009 | |Tweet
TutorialsWorking with banners
13 July 2009 | | | Supports v2.4, v2.3Tweet
Most of the sites I work on are for corporate/business clients and there is not typically a lot of fancy motion graphics going on. I do like to ensure there is some dynamic element going on, just to provide a bit of interest and one of the simplest ways to achieve this is by some variation of the random/rotating banners scenario. Of course this could equally apply to other parts of the page, not just banner graphics.Continue reading...
26 March 2009 | | | Supports v2.4, v2.3Tweet
In this tutorial we are going to create a SilverStripe theme from a static template. While completing this tutorial, you will build a good foundation for using the SilverStripe templating language and be able to create themes with dynamic menus and content areas.Continue reading...
28 October 2010 | | | Supports v2.4Tweet
In this tutorial we are going to add a form to a sidebar that can be included on any page on a website. You will be able to set whether to show the Form on a particular page via checkbox in the CMS. The work is based on the Working with SiteConfig and Creating a Simple Contact Form tutorials.Continue reading...
15 April 2010 | | | Supports v2.4, v2.3Tweet
Often when doing development work on a website - and particularly the templates - it can be a pain having to remember to add ?flush to the end of the URL to make sure all of your changes have come through. I'm sure that all of us have had that "d'oh" moment when we have spent too much time wondering why our changes weren't working, only to find a simple flush fixed it.Continue reading...
5 August 2009 | |Tweet
SnippetsResizing and Manipulating Images
22 March 2009 | | | Supports v2.4, v2.3Tweet
You can resize images from within the template very easily. But sometimes you need to resize it and just use the URL value, something you can't do by calling the resize on the variable directly (e.g. $Image.CroppedImage(200,200)). This is how we would create a cropped resize of it and still be able to use just the URL, allowing a custom <img> tag.Continue reading...