CSI: WordPress -- Getting Into the Guts

  • 2,513 views
Uploaded on

An introduction to one of the greatest features of WordPress: Extensibility. Developers area able to use plugins and themes to extend the power of WordPress through a flexible set of APIs. These APIs …

An introduction to one of the greatest features of WordPress: Extensibility. Developers area able to use plugins and themes to extend the power of WordPress through a flexible set of APIs. These APIs include pluggable functions, action and filter hooks, and metadata.

More in: Technology , Business
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
  • Dunno why Slideshare cut dropped the word 'WordPress' off the title slide in the conversion from Keynote.

    Speaking of which, if you have Keynote, download the original file to get my speaker's notes.
    Are you sure you want to
    Your message goes here
    Be the first to like this
No Downloads

Views

Total Views
2,513
On Slideshare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
4
Comments
1
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. CSI:Getting Into the GutsWordCamp Birmingham, January 14, 2012
  • 2. CSI:Getting Into the GutsWordCamp Birmingham, January 14, 2012
  • 3. Version 0.5 Please note that due to unforeseen events, I did not complete this slide deck to my satisfaction before presenting it at WordCamp Birmingham. I will be doing this presentation again at WordCampAtlanta, with an improved version of these slides. At that time, I will replace this presentation with the new, improved version which will contain more concrete developer information, code samples, and more comprehensive pointers to resources. Thank you for your understanding. -- Dougal
  • 4. WordPressRocks!
  • 5. WordPressRocks!Why?
  • 6. ExtensibilityWordPress can do just about anyfreaking thing you can think of
  • 7. Extensibility
  • 8. Extensibility✤ Rich developer APIs
  • 9. Extensibility✤ Rich developer APIs✤ Themes
  • 10. Extensibility✤ Rich developer APIs✤ Themes✤ Plugins
  • 11. API
  • 12. API✤ Application Programming Interface
  • 13. API✤ Application Programming Interface✤ “...a source code based specification intended to be used as an interface by software components to communicate with each other.” – Wikipedia
  • 14. What kind of APIs?✤ Pluggable functions✤ Hooks ✤ Actions and Filters✤ Metadata ✤ Post meta, User meta, Comment meta, Site Options✤ Custom Javascript and CSS
  • 15. PluggableFunctionsLogin/Cookie/User infoEmail notifications, wp_mail()Security: nonces, password salts &hashesAvatarsDisplay of revision diffs
  • 16. Themes✤ Sidebars and Widgets✤ Custom Headers and Backgrounds✤ Custom Post Types and Taxonomies
  • 17. Plugins
  • 18. Plugins✤ Plugins can do... practically anything:
  • 19. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages
  • 20. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages ✤ Integrate 3rd party data (Twitter, Facebook, etc.)
  • 21. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages ✤ Integrate 3rd party data (Twitter, Facebook, etc.) ✤ Extend user info
  • 22. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages ✤ Integrate 3rd party data (Twitter, Facebook, etc.) ✤ Extend user info ✤ Use Roles & Capabilities to control access to features
  • 23. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages ✤ Integrate 3rd party data (Twitter, Facebook, etc.) ✤ Extend user info ✤ Use Roles & Capabilities to control access to features ✤ Create workflows (e.g., EditFlow plugin)
  • 24. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages ✤ Integrate 3rd party data (Twitter, Facebook, etc.) ✤ Extend user info ✤ Use Roles & Capabilities to control access to features ✤ Create workflows (e.g., EditFlow plugin) ✤ Alternative login systems (LDAP, SSO)
  • 25. Plugins✤ Plugins can do... practically anything: ✤ Modify posts/pages ✤ Integrate 3rd party data (Twitter, Facebook, etc.) ✤ Extend user info ✤ Use Roles & Capabilities to control access to features ✤ Create workflows (e.g., EditFlow plugin) ✤ Alternative login systems (LDAP, SSO) ✤ The sky’s the limit!
  • 26. ActionsActions are eventsUse them to DO something, ratherthan to CHANGE something
  • 27. Actionsplugins_loaded()setup_theme()wp_init()template_redirect()wp_head()wp_footer() http://andy.wordpress.com/2008/10/30/wordpress-include-stack/
  • 28. FiltersModify existing content<?phpadd_filter( ‘the_content’, ‘lolify’ );function lolify( $text_in ) { $text out = do_cool_stuff( $text_in ); return $text_out;}?>
  • 29. MetadataLets you add additional details beyondwhat WordPress provides out-of-the-box.
  • 30. Metadata✤ “Data about Data”Lets you provide additionaldetails that may or may not bevisible on the site.
  • 31. Putting ittogether✤ codex.wordpress.org✤ make.wordpress.org✤ wpdevel.wordpress.com
  • 32. Who are you?Dougal Campbell@dougaldougal.us /dougal.gunters.orgdougal.campbell@gmail.com