Home - Your one stop SilverStripe learning resource
- Show all
- Site Tree
- Site of the Month
- Model Admin
- SilverStripe 3
SnippetsCreating a Page Export Function
6 May 2009 | | | Supports v2.4, v2.3Tweet
Need to create an 'export' function for a page? Do it quickly and cleanly with HTTP::sendFileToBrowser. In your page controller, add a new action 'export':Continue reading...
27 December 2010 | |Tweet
The Votes are in! And the winner of December's SSbits Site Of The Month is.....Continue reading...
19 January 2011 | |Tweet
So here we are, after a slightly longer than usual wait: The January 2011 Site of the Month Finalists! There are some really great sites this month so vote on your favourite now!Continue reading...
30 March 2011 | |Tweet
The Votes are in! And the winner of March's SSbits Site Of The Month is.....Continue reading...
4 October 2011 | |Tweet
Enter your site for a chance to be in the final 5 vote off! Voting will begin on the 12th of October.Continue reading...
17 February 2010 | | | Supports v2.4, v2.3Tweet
Wouldn't it be easy to have a single environment configuration for all your SilverStripe sites without having to reconfigure each one individually? Wouldn't it be great not to have to change environment settings when you push your site from development to live servers? This is easy to achieve using the SilverStripe "ConfigureFromEnv" script.Continue reading...
28 October 2009 | |Tweet
In my most recent project I've had to run a site in another language (Swedish) and run into some issues which I thought I'd share with all of you. Now Silverstripe probably comes with a translation for your language but even if it does, you probably want to change the wording of some of the phrases, so what to do? You could of course hit up the language files for the relevant module or the ones in cms and sapphire but you really don't want to touch these files if you can help it.Continue reading...
22 August 2009 | |Tweet I managed to forget my admin password and found quite a few ways to unlock an SS install. I originally thought about poking around the database and changing the hashes myself. After reviewing the Security and password encryption code, I would recommend against doing that. SilverStripe uses salted SHA1 encryption which is no fun to try and create yourself. Also you'd have to update multiple tables to get the password changed. Luckily the SS Core team has included multiple features for accomplishing this. The options below assume you have access to your webserver to use some PHP code. Continue reading...
23 June 2009 | | | Supports v2.4, v2.3Tweet
Often you will want to control which users can create, edit, delete and publish certain page types. For example you may only want high level users to be able to create ContactPage page types, or prevent low level users from deleting HomePage page types. This can easily be achieved by adding these functions to the page type model (usually just before getCMSFields()). Then within the function you can define conditionals which decide whether to return true or false.Continue reading...
20 October 2009 | |Tweet
As some of you might have noticed, as soon as you step outside of the standard SiteTree structure you're pretty much on your own. Today I had to make a menu that mixed normal SiteTree pages and controller actions.Continue reading...
TutorialsCreate a front end theme switcher
17 August 2009 | | | Supports v2.3Tweet
So you wanna make a demo site for your customers to show all your template skills in one site. A simple theme switcher can come in handy. It's quite easy to implement this.
First add two new functions to your Page_Controller class:Continue reading...
8 December 2010 | | | Supports v2.4Tweet
Some of you might have noticed that SilverStripe's GD class has a couple of interesting looking functions, namely rotate($angle) and greyscale($Red, $Green, $Blue). However it was never quite clear how to use these functions (at least not to me anyway!). So after a bit of trial and error, it turns out it's pretty simple to achieve by decorating the image class and adding a couple of simple functions...Continue reading...
15 January 2011 | | | Supports v2.4Tweet
One way to change the MetaTags dynamicly is to add a lot of template controls to display different MetaTags for each view, but you can get a lot more flexibility by overriding the SiteTree MetaTags function in your Page_Controller.Continue reading...
1 February 2011 | | | Supports v2.4, v2.3Tweet
In this tutorial we'll be taking a look at SilverStripes nested controller concept and how you can use it in your own projects. Keep in mind though that this tutorial is probably for the more advanced users and for those who whish to learn abit more about how SilverStripe works. I will be referencing Controllers Instead of Pages by Ty Barho and the nested controller we'll be building will be for handling his scenario.
I have also taken the liberty of including a zip file which contains all the code examples from Tys tutorial + the new controller and the new URL rule for it.Continue reading...
20 May 2011 | |Tweet
Here we have 5 excellent websites all developed in SilverStripe. But which one is best? You decide!Continue reading...