Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
SilverStripe Introduction
Search
Philipp Krenn
April 08, 2015
Programming
1.4k
0
Share
SilverStripe Introduction
SilverStripe introduction given at the ViennaPHP and Drupal Vienna meetup groups
Philipp Krenn
April 08, 2015
More Decks by Philipp Krenn
See All by Philipp Krenn
Full-Text Search Explained
xeraa
11
2.4k
360° Monitoring of Your Microservices
xeraa
7
3.6k
Scale Your Metrics with Elasticsearch
xeraa
4
170
YAML Considered Harmful
xeraa
0
2.1k
Scale Your Elasticsearch Cluster
xeraa
1
350
Hands-On ModSecurity and Logging
xeraa
2
220
Centralized Logging Patterns
xeraa
1
1.2k
Dashboards for Your Management with Kibana Canvas
xeraa
1
510
Make Your Data FABulous
xeraa
3
1.1k
Other Decks in Programming
See All in Programming
(Re)make Regexp in Ruby: Democratizing internals for the JIT
makenowjust
3
1.1k
実践ハーネスエンジニアリング:ステアリングループを実例から読み解く / Practical Harness Engineering: Understanding Steering Loops Through Real-World Examples
nrslib
5
5.5k
TypeScriptだけでAIエージェントを作る フロント・エージェント・インフラのフルスタック実践
har1101
3
490
サーバーレスで作る、動画データ管理基盤
oyasumipants
0
210
属人化しないコード品質の作り方_2026.04.07.pdf
muraaano
1
360
🦞OpenClaw works with AWS
licux
1
370
WebAssembly を読み込むベストプラクティス 2026年春版 / Best Practices for Loading WebAssembly (Spring 2026)
petamoriken
5
1.1k
いつか誰かが、と思っていた フロントエンド刷新5年間の実践知
kiichisugihara
1
280
AlarmKitで明後日起きれるアラームアプリを作る
trickart
0
140
Oxlintはいかにしてtsgolintのlint ruleを呼び出しているのか
syumai
0
210
HTML-Aware ERB: The Path to Reactive Rendering @ RubyKaigi 2026, Hakodate, Japan
marcoroth
0
720
Agentic UI in the Frontend: Architectures with Open Standards @JAX 2026 in Mainz
manfredsteyer
PRO
0
120
Featured
See All Featured
Leveraging Curiosity to Care for An Aging Population
cassininazir
1
240
Test your architecture with Archunit
thirion
1
2.2k
From π to Pie charts
rasagy
0
180
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.9k
What's in a price? How to price your products and services
michaelherold
247
13k
Heart Work Chapter 1 - Part 1
lfama
PRO
7
35k
Crafting Experiences
bethany
1
150
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.8k
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
140
How to Talk to Developers About Accessibility
jct
2
200
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
61
44k
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
780
Transcript
Philipp Krenn @xeraa https://xeraa.net
Background Google Summer of Code Student 2007 Multiple Database Support
Background
Background GSoC Mentor 2012: Yuki Awano Content Personalization
Ecosystem BSD licensed — http://www.silverstripe.org SilverStripe Ltd. — http://www.silverstripe.com
Development 2007 2008 2009 2010 2011 2012 2013 2.0 3.1
3.0 2.4 2.3 2.1 2.2 2014 2015 3.2
Installation
Requirements Apache httpd, nginx, lighttpd, IIS PHP 5.3+ MySQL 5.0+
PostgreSQL 8.3+, SQL Server 2008+, SQLite 3.3+ via modules Chrome, Firefox, IE 8+ (Safari) for the CMS Composer recommended
Preparation Empty database silverstripe nginx configuration _silverstripe3: https://gist.github.com/xeraa/9527232 server {
root /Users/philipp/Sites/silverstripe; server_name silverstripe.local; include _silverstripe3; } /etc/hosts: 127.0.0.1 http://silverstripe.local
Installation $ composer create-project silverstripe/installer ~/Sites/silverstripe 3.1.12 http://silverstripe.local $ chmod
-R 777 ~/Sites/silverstripe/assets/ $ chmod 777 ~/Sites/silverstripe/mysite/_config.php
CMS
Overview http://silverstripe.local/admin/ Pages Reports Files Security Settings
First Steps Change the CMS language and date formats Change
the site title and slogan
Pages Content Settings History Viewing modes Split (screen size dependent)
Preview including different devices Edit
CSS themes/simple/css/typography.css .typography h1 { … background: #ee5757; } Force
reload in the CMS
Under the Hood Database tables SiteConfig SiteTree, SiteTree_Live, SiteTree_versions
Framework
Basics MVC Pulling data, not pushing it Object-oriented — extension
via inheritance / mixins Everything is code
Template Structure mysite/templates/, mysite/css/,… themes/<name>/templates/, themes/<name>/ css/,… themes/ Includes/ Layout/Page.ss
(optionally more) Page.ss
Template Elements $Title, $Content, $SiteConfig.Title <% loop $Menu(1).Limit(5) %> $Link
<% end_loop %> <% if not $Children %> … <% end_if %> <% with $CurrentMember %> $FirstName <% end_with %>
Template Changes templates/Includes/Footer.ss Proudly powered by SilverStripe templates/Page.ss <% include
Subfooter %> templates/Includes/Subfooter.ss <p>© Philipp Krenn</p>
http://will-rossi.deviantart.com/art/SilverStripe-WallPaper-01-59254232
Triggering an Error Delete an <% end_… $> mysite/_config/config.yml: dev,
test, live Director: environment_type: 'dev'
A New Page Type mysite/code/MeetupPage.php — Model and Controller themes/simple/templates/Layout/
MeetupPage.ss — View
Model 1/2 class MeetupPage extends Page { private static $db
= array( 'Date' => 'Date', 'Type' => 'Enum("Unknown, PHP, Symfony, Drupal, SilverStripe", "Unknown")', ); private static $has_one = array( 'Logo' => 'File', );
Model 2/2 public function getCMSFields() { $fields = parent::getCMSFields(); $dateField
= new DateField('Date'); $dateField->setConfig('showcalendar', true); $fields->addFieldToTab('Root.Main', $dateField, 'Content'); $fields->addFieldToTab('Root.Main', new DropdownField('Type', 'Type of event', singleton('MeetupPage')->dbObject('Type')-> enumValues()), 'Content'); $fields->addFieldToTab('Root.Main', new UploadField('Logo'), 'Content'); return $fields; }
Controller class MeetupPage_Controller extends Page_Controller { }
Synchronize the Database http://silverstripe.local/dev/build?flush=all Add new page in the CMS
View <% include SideBar %> <div class="content-container unit size3of4 lastUnit">
<article> <h1>$Title</h1> <h2> $Type <% if $Type == "SilverStripe" %>*yeah*<% end_if %> </h2> <h3>$Date</h3> <img src="$Logo.URL" alt="logo"> <div class="content">$Content</div> </article> $Form $PageComments </div>
Much More DataObjects and Scaffolding Powerful forms with GridField Object-Relational
Mapper RESTful API SOAP API Extensible permission system
And a Little Less Smallish community outside of New Zealand
and Australia A manageable number of modules Hint: https://github.com/search?q=silverstripe- &type=Repositories Few (good) themes
More Information http://www.silverstripe.org https://github.com/silverstripe http://www.meetup.com/SilverStripe-Austria http://vimeo.com/silverstripe
Try It https://github.com/xeraa/silverstripe-nginx
Thanks Questions? Now @xeraa
[email protected]