WordPress Development



WordPress Development

0 0


csu-wordpress-development

WordPress Development Talk for CSU CT 310

On Github roadwarriorwp / csu-wordpress-development

WordPress Development

Amber Hinds

Why WordPress?

Because copy/pasting content is boring.

Lots of resources for learning.

Open source.

Large collaborative community.

What is a WordPress developer?

Someone who...

Builds & sells commercial software products.

Works in-house on a single WP website.

Builds/modifies WP websites for clients.

Combination of coding from scratch, modifying someone else's code, and clicking buttons in a CMS.

Modifying WordPress

Check out the "core" files - know what's there...

but don't change it!

With every WordPress update, most of these files get overwritten.

When WordPress updates, your safe zone is:

  • .htaccess
  • wp-config
  • wp-content directory contents
  • any non-WP files you have in the root

WP devs build themes and plugins.

Themes

Control style only (best practice; not always reality)

Plugins

Control functionality and (to some degree) style

Jargon and Other Things To Know...

"Posts" & "Pages"

"posts" = blog posts - content related to one another by category/tags (taxonomies) and by date

"pages" = stand-alone content that may have a hierarchical relationship to one another or none at all - more static

Actually it's all the same

...they are all stored in the same table: wp_posts

Extra details about content is stored in wp_postmeta & is linked by the post id

Custom Post Types

Create your own as a way of better organizing content...

  • staff
  • portfolio items
  • products
  • recipes
  • and more...

Learn More

Widgets

Mini programs/tools that can be added to repeatable areas of the site - header, footer, sidebars, etc.

  • Found under Appearance > Widgets
  • "Widget Areas" are created by the theme
  • "Widgets" can come from core, plugins, and/or theme

Learn more...

Shortcodes

A way of adding macros - code fragments - in the body of a post or page

Learn more...

Theme Development

Themes live in /wp-content/themes

More than a skin - the front of the website will literally not function without a theme.

Themes control the look of the website and also pull content out of the database.

Themes can be:

  • Stand alone & static
  • Part of a framework - they update!
  • Child theme, adopting most styles from a parent theme

Themes contain

  • Stylesheet - style.css (+ index.php are bare minimum for a child theme)
  • Functions file - functions.php
    • enqueue stylesheets & scripts
    • Add features - widget areas, custom image handling, etc.
    • Set up options for users
  • Template Files - PHP source files used to generate the pages requested by visitors, and are output as HTML

Learn more...

Plugin Development

Plugins add functionality or modify functionality of WordPress

Some plugins modify the functionality of other plugins.

Plugins live in wp_content/plugins...and don't even have to be in a directory.

Looking at a basic plugin

Enable Contributor Uploads

Learn more...

Tools

Resources

From WordPress

Books

Podcasts/Hangouts on Air

Other Resources

Fort Collins WordPress Meetup

Building Extensible PluginsTuesday, May 17th @ 6pm

Meetup.com/Fort-Collins-WordPress-Meetup

Questions?

WordPress Development Amber Hinds