App-ifying WordPress: Practical Tips for Using WordPress as an Application Platform by Mandi Wise for WordCamp Vancouver 2014
WP as an AP WTF?
From The State of the Word 2013
From The State of the Word 2013
App vs. Website
Tasks vs. Content Photo Credit: JD Hancock
Action-oriented vs. Information-oriented Photo Credit: JD Hancock
Creation vs. Consumption Photo Credit: JD Hancock
Many of us likely live here App Site
What Makes an App?
Multi-Tier Architecture Presentation Tier Application Tier Database Tier
Platform vs. Framework
Why WordPress? Already known and loved. Much of the work has been done for you. Plenty of documentation and examples.
But Should you?
–Dr. Ian Malcolm “Your scientists were so preoccupied with whether they could they didn’t stop to think if they should.”
Who’s Already Doing It?
PressBooks Turn WP Multisite into a self-hosted writing/publishing app by installing the PressBooks theme.
Happytables Create, host, and manage a website for your restaurant using the Happytables website builder.
Quartz Backbone.js business up front, WordPress party in the back.
DMA Friends An app built with BadgeOS and a WordPress- powered back-end to increase audience engagement at the Dallas Museum of Art.
AppPresser A plugin for creating native mobile apps by integrating PhoneGap with WordPress.
Different strokes for different folks.
Your WordPress Toolbox
Custom Post Types The world is your custom post type oyster. Remember all the $args!
Custom Taxonomies A powerful way to filter, sort and connect your post types and their posts.
Metaboxes & Settings Almost inevitable you’ll end up using these… Check out Custom Metaboxes and Fields on Github.
User Roles, Caps & Meta Key to customizing and controlling user permissions in your app.
Admin Themes The WordPress admin area doesn’t have to look like WordPress anymore.
The Dashboard There’s a good chance you won’t want the default dashboard widgets in your app.
Templating Drag and drop your way to templated bliss… maybe.
Don’t Forget! Multisite BuddyPress And all of these other things…
HeartBeat API wp_mail, wp_Cron & wp_ajax Custom Database Tables Posts 2 Posts Gravity Forms eCommerce Plugins Membership Plugins (…You Get the Point)
That all sounds great, but what’s still missing?
Some APIs aren’t as user-friendly as they could be. I’m looking at you, Settings API. Custom post statuses are only half-way there. Customizing the 3.5+ media uploader can be tricky if you don’t have some Backbone chops. Very real real-time limitations. Some things don’t like to be messed with.
Things to think about
Theme or Plugin?
Get Organized Photo Credit: Pietro Bellini
Protect Your Users Photo Credit: JD Hancock Take privacy protection seriously. Look for easy backdoors. SSL where it’s needed. It’s 10pm. Do you know where your servers are?
Protect Yourself(Because unlike these guys, you don’t have a time machine.) Malware and brute force attacks. Custom database prefixes. Data validation, sanitization, and escaping. Use nonces. Prepare and escape your custom SQL queries. Make back-ups. Then back-up your back-ups.
Debug & test
Will it scale? Hosting that can grow with you. Caching and transients. LEMP (nginx) vs. typical LAMP stack. Minify scripts and styles, optimize images. Localize your text strings for translation.
Extending & Maintaining Borrowed from xkcd.com
The Road Ahead...
JSON REST API Pick your flavour: Jetpack or WP API (in 4.1 core)
JavaScript, Javascript, Javascript The Media Uploader was only the beginning…
More and More Front-End Development of a front-end editor for core is well-underway at make.wordpress.org.
Metadata UI API? Still very alpha, but exciting to stalk on make.wordpress.org and Github!
Finally, Some Resources: github.com/mandiwise/appifying-wp-resources
Thanks On Twitter and Github: @mandiwise

App-ifiying WordPress: Practical Tips for Using WordPress as an Application Platform