the dawson way of doing things: a study of our path using wordpress
TRANSCRIPT
The Way of Doing ThingsA STUDY OF OUR PATH USING WORDPRESS
D AW S O N C O L L E G E
@ M Y D AW S O N C O L L E G E
W W W. D AW S O N C O L L E G E . Q C .C A
J O N AT H A N P E R L M A N
@ J P U R P L E M A N
W W W. J P U R P L E M A N .C A
Jonathan Perlman
• Canadian, eh! Montreal, Quebec
• Senior web developer at Dawson College
• Teacher at Dawson College’s CTD ( non-credit )
• WordCamp speaker
• Member of WPCampus
@jpurpleman | jpurpleman.ca
@jpurpleman | jpurpleman.ca
Dawson College at a glance
@jpurpleman | jpurpleman.ca
15,000+ 10,000+ 1,000+
• Technical / vocational institution
• Centralized IT & Communications departments forstudents, faculty and staff
The Early Years
@jpurpleman | jpurpleman.ca
2002 – Unified website branding
@jpurpleman | jpurpleman.ca
2006 – New home page and header
@jpurpleman | jpurpleman.ca
2006 - Department / program websites
@jpurpleman | jpurpleman.ca
2006 - CMS based sites
@jpurpleman | jpurpleman.ca
@jpurpleman | jpurpleman.ca
2008 Redesign
@jpurpleman | jpurpleman.ca
2008 – Unified website branding
@jpurpleman | jpurpleman.ca
2010 – Blogs & Writing in Disciplines
@jpurpleman | jpurpleman.ca
2013 Redesign
@jpurpleman | jpurpleman.ca
2013 – Long Overdue Redesign
• Editing content wasn't easy for the non-tech
• Multi-lingual support was non-existant
• Technical support was slow to respond / not reliable
• Support for CMS was dropped
@jpurpleman | jpurpleman.ca
2013 – Identify Platform
@jpurpleman | jpurpleman.ca
2008
@jpurpleman | jpurpleman.ca
2014 – Phase 1
@jpurpleman | jpurpleman.ca
2014 – 7 Month Migration
ImportAudit & Identify
Import Selection
Build a theme
Release Same Design
Reformat In WP
@jpurpleman | jpurpleman.ca
Migrating…
• PHP + Curl + Simple Dom
• http://simplehtmldom.sourceforge.net
• Created posts with wp_insert_post()
• Set meta value with ID of old page
• Categories
• Keep
• Revise
• Trash
• Wtf?!?
@jpurpleman | jpurpleman.ca
Looking back
• Successes:
• Multi-site
• We moved quickly
• Community didn't realize we were on a brand new platform
• Downsides:
• Redirect, redirect, redirect – 1900+
• Edit two sites in parallel
@jpurpleman | jpurpleman.ca
2015 – Mobile & Responsive
@jpurpleman | jpurpleman.ca
Tips
• Create new ( unused ) menus in production and replicate it in development
• Don’t revise content in development and wait to release it• Leads to editing dev site and production site in parallel
• Beta periods may invite too much feedback• Keep them short!
• Produce documentation about the overhaul
• Highlight new features and explain choices
@jpurpleman | jpurpleman.ca
Current Status
@jpurpleman | jpurpleman.ca
Web staff
IT
3
Communications
1
Staff & Faculty
200+
@jpurpleman | jpurpleman.ca
Web sites
• www.dawsoncollege.qc.ca
• Computer Science
• Nursing
• Human Resources
• Registrar's Office
• Student Fees
• athletics.dawsoncollege.qc.ca
• library.dawsoncollege.qc.ca
• maps.dawsoncollege.qc.ca
@jpurpleman | jpurpleman.ca
150
25+
Page views as per Google Analytics
300,000
400,000
500,000
600,000
700,000
800,000
Jun-15 Jul-15 Aug-15 Sep-15 Oct-15 Nov-15 Dec-15 Jan-16 Feb-16 Mar-16 Apr-16 May-16 Jun-16
@jpurpleman | jpurpleman.ca
WordPress infrastructure
@jpurpleman | jpurpleman.ca
Main website visitors
Web server environment
• Virtualized web servers• 16G of ram
• 4 cores
• Nginx & PHP-FPM
@jpurpleman | jpurpleman.ca
Security Posture
• Fortinet WAF controlling the network
• Nginx rules to block common attacks
• Direct access to files within WordPress core
• xmlrpc.php
• SQL Injection
• Unwanted user-agents
• Login page restricted to Dawson College network
@jpurpleman | jpurpleman.ca
Database server environment
• Virtualized database servers
• 16G of ram
• 4 cores
• MariaDB
• Every WordPress install has a unique username and password in wp-config.php
@jpurpleman | jpurpleman.ca
Backups
• Virtual machine backups via Veem
• MySQL Auto Backup
• https://sourceforge.net/projects/automysqlbackup/
• Daily
• Weekly
• Monthly
• Send data off-site
@jpurpleman | jpurpleman.ca
WordPress updates
• Auto-update disabled
• Everything is version controlled
• We never push out X.X
• We always wait for X.X.1
• Reasons for waiting
• Stability
• Bug fixes for the major release
@jpurpleman | jpurpleman.ca
Project Build
@jpurpleman | jpurpleman.ca
Project environments
• Every project has minimum two copies
• Every developer has their own install
• Example: www.dawsoncollege.qc.ca
• Chris, Elisabeth, Jonathan
• Staging
• Production
• Push and pull database content via command line
@jpurpleman | jpurpleman.ca
Tools
• PHPStorm
• WP Awesome Config
• Git
• WP-CLI
• WP Migrate DB Pro
• Custom bash scripts
• https://github.com/jpurpleman/WordPress-Stuff
@jpurpleman | jpurpleman.ca
WP Awesome Config
• https://gist.github.com/ashfame/1923821
@jpurpleman | jpurpleman.ca
Git• We track
• Core• Must-use Plugins• Plugins• Themes
• We don't track• local-config.php• dev-config.php• staging-config.php• production-config.php• .DS_STORE• *.log• .htaccess• sitemap.xml• sitemap.xml.gz• wc-logs/*• wp-content/blogs.dir/• wp-content/cache/• wp-content/upgrade/• wp-content/uploads/
@jpurpleman | jpurpleman.ca
Committing plugins
123438b Adding plugin: WordPress Importer at version 0.6.2
449e092 Updating plugin: Print Friendly and PDF to version 3.4.6
8d2d7e3 Updating plugin: WP Migrate DB Pro Media Files to version 1.4.4
ce0181e Updating plugin: WP Migrate DB Pro to version 1.6
3a37bd6 Updating plugin: Gravity Forms + Custom Post Types to version 3.1.3
91e2560 Updating plugin: jQuery Responsive Select Menu to version 1.5.0
83af679 Updating plugin: Gravity Forms to version 1.9.19
@jpurpleman | jpurpleman.ca
git-wp-commit-object()https://github.com/jpurpleman/WordPress-Stuff/blob/master/.bashrc
Themes and Plugins
@jpurpleman | jpurpleman.ca
Themes
• Underscores
• Canvas by WooCommerce
• Twenty Seventeen
• Twenty Sixteen
• Twenty Fifteen
• https://www.wordpress.org/themes
@jpurpleman | jpurpleman.ca
Tips
• In a multi-site setup
• Create your own parent themes
• Go with as little theme options as possible
• In a single site install
• Child theme as much as possible
@jpurpleman | jpurpleman.ca
Plugins
• Admin Columns
• Advanced Custom Fields
• CMB2
• Disable Emoji's
• Gravity Forms
• Mapplic
• Next Active Directory Integration
• Responsive Menu
• SportsPress Pro
• The Events Calendar
• TinyMCE Advanced
• User Switching
@jpurpleman | jpurpleman.ca
Tips
• Find plugins with reputable histories
• Use plugins that are supported and up-to-date
• Most are multi-site friendly but some are not
• Plugins like Advanced Custom Fields are heavy on the database and hard to maintain
@jpurpleman | jpurpleman.ca
We use WordPress for…
@jpurpleman | jpurpleman.ca
Primary website
@jpurpleman | jpurpleman.ca
Conference sites
@jpurpleman | jpurpleman.ca
Specialty sites
@jpurpleman | jpurpleman.ca
Specialty sites
@jpurpleman | jpurpleman.ca
Research grant projects
@jpurpleman | jpurpleman.ca
Research grant projects
@jpurpleman | jpurpleman.ca
Research grant projects
@jpurpleman | jpurpleman.ca
Web-based applications
@jpurpleman | jpurpleman.ca
Web-based applications
@jpurpleman | jpurpleman.ca
Blogs
@jpurpleman | jpurpleman.ca
Show and tell!
@jpurpleman | jpurpleman.ca
Custom Backend Login
@jpurpleman | jpurpleman.ca
Custom dashboard widgets
@jpurpleman | jpurpleman.ca
Custom dashboard widgets
Admin Additions
• Editor level roles for most users
• Custom post types for content
• Ability to create forms
• Allowed the use of Customizer
@jpurpleman | jpurpleman.ca
Admin Additions
• Added User Guides to the pull down help
@jpurpleman | jpurpleman.ca
Contact blocks with Shortcode UI
@jpurpleman | jpurpleman.ca
Contact blocks with Shortcode UI
@jpurpleman | jpurpleman.ca
Contact blocks with Shortcode UI
@jpurpleman | jpurpleman.ca
SharePoint Management
@jpurpleman | jpurpleman.ca
Looking Forward
@jpurpleman | jpurpleman.ca
Looking forward
• Iterative improvements pushed more frequently
• More web application development on WordPress
• Connecting sites and sharing data withREST API
@jpurpleman | jpurpleman.ca
Thank you!Questions?
D AW S O N C O L L E G E
@ M Y D AW S O N C O L L E G E
W W W. D AW S O N C O L L E G E . Q C .C A
J O N AT H A N P E R L M A N
@ J P U R P L E M A N
W W W. J P U R P L E M A N .C A