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.

Delicious tutorials.

Master SilverStripe, one bite at a time.

 

Versions

Introduction to SilverStripe (7 videos)

Get going in just over an hour.

Up and Running: Setting up a local SilverStripe dev environment

In this introductory lesson, we cover installing a local webserver (e.g. MAMP), installing and using Composer, and configuring an _ss_environment.php file. Having a finely tuned local environment for your projects will help you work faster and with less redundancy.

All tutorials (25 articles)

Data Extensions and SiteConfig

In this tutorial, we'll discuss one of the major building blocks of modular and reusable code in SilverStripe Framework: extensions. We won't be writing a whole...

Introduction to ModelAdmin

In this lesson, we'll create the Property object that will drive most of the content in our application, and add a management interface for it in...

Controller Actions / DataObjects as Pages

In this lesson, we'll introduce the concept of a controller action, which is a URL route that executes a function on a controller.

Building a Search Form

In this lesson, we'll create a form that can filter our listings by multiple parameters.

Lists and Pagination

In this lesson, we'll do an overview of different types of lists in SilverStripe, and we'll use PaginatedList to add pagination to our search results.

Ajax Behaviour and ViewableData

In this tutorial, we'll add some Ajax behaviour to our site and cover a key player in the SilverStripe Framework known as ViewableData.

Dealing with arbitrary template data

In this tutorial, we're going to talk about adding non-database content to our templates.

Creating Filtered Views

In this lesson we'll talk about filtering a list of items on a template through the navigation.

Beyond the ORM: Building custom SQL

In this tutorial, we'll build a date archive using custom SQL queries, and introduce the SQLQuery class.

Advanced Environment Configuration

In this lesson, we'll talk about going beyond simple _ss_environment.php configurations and discuss how to deploy targeted functionality toward dev, test, and live environments.

Dependencies and Modules

In this lesson, we'll talk about how Composer works, and we'll use it to upgrade SilverStripe and install a module.

Creating Great Open Source Modules

In this lesson, we'll look at how to improve the quality of your modules, so more people will use them.

How to use this guide

What are we building?

These tutorials are published in series, with each lesson demonstrating a new concept in SilverStripe development. To give them context, we have created an imaginary client that we’ll be working for, who needs a custom web application. Their application will allow users to book and list holiday rentals, much like HomeAway or AirBnB, only to give it an element of distinction, all the listings are in Middle Earth. The name of the website is appropriately One Ring Rentals.

Prerequisites

You should have a basic working knowledge of object-oriented PHP and MySQL. If you are new to PHP, we recommend Sitepoint. Since the project assumes that a designer has already done all of our HTML and CSS, there will be very little, if any, frontend work.

The format

Each lesson includes a screencast and a written tutorial. They follow each other very closely, and in general, share all the same information. Lessons will be published at a rate of roughly one per week, and will move through the project in a linear fashion, putting most of the advanced topics further down the track.

Getting the source code

The source code is hosted on Github in a public repository.

Each lesson points to a commit in the source code repository, tagged with the lesson name, formatted as ‘lesson-x’, where “x” is the number of the lesson. For example, to see the final result of lesson 5, you can use git checkout lesson-5. Keep in mind, the tags are assigned at the conclusion of the lesson, so to follow along and do the work on your own, you should check out the previous lesson.

Getting the database and assets

With the exception of the early lessons, each lesson contains a ZIP file download of the database, uploaded assets, and any other materials you may need. All database clients, such as PHPMyAdmin, Navicat, and Sequel Pro allow you to import SQL scripts very easily. You can also run the script from the command line, using

mysql -u [user] -p[password] [database_name] < import.sql

Getting support

The SilverStripe Community Slack channel, the SilverStripe Forum, and Stack Overflow (tagged SilverStripe or SilverStripe 4) should be your first point of call for any questions you may have. For more information about the various ways of connecting with the SilverStripe community refer to our Contributing guides.

Translations

In the future, we plan to add subtitles to the screencasts, but for now, non-English speakers should translate the written version of the tutorials to follow along.