Getting Started With WordPress Development
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Getting Started With WordPress Development

on

  • 8,625 views

A presentation from Iowa Code Camp 2010 by Kenny Younger (@kenny) and Andy Brudtkuhl (@abrudtkuhl)

A presentation from Iowa Code Camp 2010 by Kenny Younger (@kenny) and Andy Brudtkuhl (@abrudtkuhl)

Statistics

Views

Total Views
8,625
Views on SlideShare
6,781
Embed Views
1,844

Actions

Likes
5
Downloads
237
Comments
0

9 Embeds 1,844

http://www.flarereviews.com 1334
http://flarereviews.com 467
http://48web.com 26
http://www.linkedin.com 6
http://www.slideshare.net 4
https://ric-staging2.blackboard.com 4
http://www.lmodules.com 1
http://feeds.feedburner.com 1
http://swazzy.com 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • Describe each table.

Getting Started With WordPress Development Presentation Transcript

  • 1. Intro To WordPress Development
    Kenny Younger (@kenny)
    &
    Andy Brudtkuhl (@abrudtkuhl)
  • 2. What does WordPress look like to the users?
    Let’s take a look!
  • 3. Database
  • 4. Database Schema
    Source: SchemaBank.com
  • 5. File Structure
  • 6. /
    wp-admin/
    wp-content/
    plugins/
    Each plugin usually has its own directory
    themes/
    Each theme has its own directory
    uploads/
    Created on first upload (default location)
    wp-includes/
    wp-config.php
  • 7. wp-config.php
    define('WP_ALLOW_MULTISITE', true);
  • 8. Debugging made easy
    Debugging flags added to wp-config.php:
    define( 'WP_DEBUG', true );
    define( 'SCRIPT_DEBUG', true );
    define( 'SAVEQUERIES', true );
    $wpdb->queries
    “All” hook:
    add_action( 'all', create_function( '', 'var_dump( current_filter() );' ) );
    Core Control Plugin:
    http://wordpress.org/extend/plugins/core-control/
    Dump Environment Plugin:
    http://wordpress.org/extend/plugins/dump_env/
    Source: http://www.andrewnacin.com/2010/04/23/5-ways-to-debug-wordpress/
  • 9. WordPress Themes
    What are themes? A way to skin WordPress
  • 10. What’s In A WordPress Theme?
    WordPress themes are a combination of PHP, CSS, and image files
    Requirements:
    HTML
    CSS
    Some PHP
  • 11. Anatomy Of A WordPress Theme
  • 12. Theme Structure
    Index.php
    includes header.php
    Includes sidebar.php
    Includes footer.php
  • 13. Standard Theme Architecture
    Homepage
    index.php
    home.php
    Single Post
    single.php
    Page
    page.php
    Category
    category.php
    archive.php
    • Tags
    • 14. tag.php
    • 15. Search Results
    • 16. search.php
    • 17. 404
    • 18. 404.php
  • 19. The Stylesheet – style.css
    The comment headers in the style.css provide meta info to WP are are REQUIRED
    Thisstylesheet also controls the layout and design elements of your theme…
  • 20. Functions.php
    Contains theme related functions and commonly is used to generate dynamic sidebars
  • 21. The Loop
    If (havePosts)
    show post stuff
    Else
    nothing here!
    End if
  • 22. Template Tags
    • the_title()
    • 23. the_permalink()
    • 24. the_content()
    • 25. the_excerpt()
    • 26. And more!
  • Theme Frameworks
  • 27. What Is A WordPress Plugin?
    Plugins are used to add or enhance functionalities of your WordPress site
  • 28. The Plugin Directory
    http://wordpress.org/extend/plugins/
  • 29. The Plugin API
    The API provides “Hooks” into WordPress
    No more hacking the core
    Made up of Actions and Filters
    Actions = functions triggered by events
    ie: Call function on user log in
    Filters = functions that modify information
    ie: Add facebook share button before post
  • 30. Plugin Data
    Sometimes it’s necessary to store data…
    For large amounts, create a new database table
    For small amounts, use WordPress “Options” – a table with key/value pairs
  • 31. Admin Menus
    Custom option panels for users to update settings for your plugin
    Adds options in WordPress Admin Dashboard
  • 32. Users & Roles & Capabilities
    WordPress is designed to handle multiple users – from admin and editors to subscribers
    5 Pre-Defined Roles
    Administrator
    Editor
    Author
    Contributor
    Subscriber
    http://codex.wordpress.org/Roles_and_Capabilities
  • 33. Custom Fields
    Allow attaching meta-data to posts.
    http://www.smashingmagazine.com/2010/04/29/extend-wordpress-with-custom-fields/
  • 34. Custom Post Types
    Used for:
    Real Estate Listing
    Event Calendar
    Movie Database
    Issue Management / Ticket System
    Etc.
  • 35. Custom Post Type Options
    label
    singular_label
    description
    public – query-able from public?
    menu_position
    menu_icon
    hierarchical
    query_var
    capability_type – permissions
    supports
    rewrite
    taxonomies
    register_meta_box_cb
    permalink_epmask
  • 36. Custom Post Types – Integration with the loop
    <?php $loop = new WP_Query( array( 'post_type' => my_custom_post_type', 'posts_per_page' => 10 ) ); ?>
    <?php while ( $loop->have_posts() ) : $loop->the_post(); ?>
    <?phpthe_title( '<h2 class="entry-title"><a href="' . get_permalink() . '" title="' . the_title_attribute( 'echo=0' ) . '" rel="bookmark">', '</a></h2>' );
    ?>
    <div class="entry-content">
    <?phpthe_content(); ?>
    </div>
    <?phpendwhile; ?>
  • 37. Taxonomies
    What are taxonomies?
    register_taxonomy()
    Shows up in menu system
    Demo
    register_taxonomy(
    'actor',
    'post',
    array(
    'hierarchical' => false,
    'label' => __('Actors', 'series'),
    'query_var' => 'actor',
    'rewrite' => array( 'slug' => 'actors' )
    )
    );
  • 38. Core Development
    Versioning
    0.1 increments
    Based on time, not features
    Generally every 5-6 months
    0.0.1 – usually security fixes, other small bug fixes
    Always update!!
    Mailing lists:
    http://codex.wordpress.org/Mailing_Lists
    Trac:
    http://core.trac.wordpress.org
  • 39. Resources
    Planet - planet.wordpress.org
    WordPress Codex – codex.wordpress.org
    WordPress Forums – wordpress.org/support
    All Things WordPress- wordpress.alltop.com
    Core Development Blog – devel.wordpress.org
  • 40. August 7th, Downtown Des Moines Public Library
  • 41. Thanks!!!
    Kenny Younger (@kenny)
    &
    Andy Brudtkuhl (@abrudtkuhl)