Chris everson-wchtx-2010

26
Exploring Theme Development

Transcript of Chris everson-wchtx-2010

Page 1: Chris everson-wchtx-2010

Exploring Theme Development

Page 2: Chris everson-wchtx-2010

Diving In

• Plan Your Build• Development Environment• Frameworks• The Codex• WP_Query• Workflow• Deploying Your Theme• To Infinity and Beyond!

Page 3: Chris everson-wchtx-2010

Plan Your Build

Page 4: Chris everson-wchtx-2010

Set Your Path

• Know what you want before pen hits paper.

• Is the theme going to be for a single project or is it going to be reused?

• What can I get this theme to do?What do you want your theme to do?

• Is WordPress right for this project?

PLAN YOUR BUILD

Page 5: Chris everson-wchtx-2010

Wireframe

• Draw it out!

• Digital VS Analog

• Not the designer? Blueprint it.

PLAN YOUR BUILD

Page 6: Chris everson-wchtx-2010

No Page Left Behind

• Know what page types you might use.

• Public Release? Include the defaults.

PLAN YOUR BUILD

Page 7: Chris everson-wchtx-2010

Development Environment

Page 8: Chris everson-wchtx-2010

Physical Environment

• Code is poetry, your workspace should be too.

• Avoid distraction.

• Respect your sanity or lack thereof, take some breaks chief!

DEVELOPMENT ENVIRONMENT

Page 9: Chris everson-wchtx-2010

Essential Tools

• Your software is your team.– Text editor– FTP Client– Image editing– Utilities

• Code Snippet Storage• Digital Color Meter• Firebug• On-screen ruler

DEVELOPMENT ENVIRONMENT

Page 10: Chris everson-wchtx-2010

Hosting

• Mimic the anticipated deployment environment.

• Local hosting VS Remote hosting

DEVELOPMENT ENVIRONMENT

Page 11: Chris everson-wchtx-2010

Local Filesystem Efficiency

• Organize your files!

• Become a packrat, avoid a headache.

DEVELOPMENT ENVIRONMENT

Page 12: Chris everson-wchtx-2010

Frameworks

Page 13: Chris everson-wchtx-2010

What Are They?

• Your almost-blank canvas.

• Benefits you ask? Frameworks are a huge time saver.

FRAMEWORKS

Page 14: Chris everson-wchtx-2010

Options

• Build your own?

• Popular frameworks– Thematic ( themeshaper.com/thematic/ )– Sandbox ( plaintxt.org/themes/sandbox/ )– Hybrid ( themehybrid.com/themes/hybrid/ )

FRAMEWORKS

Page 15: Chris everson-wchtx-2010

The Codex

Page 16: Chris everson-wchtx-2010

Template Tags

• The Template Tags portion of The Codex covers tags used frequently in standard template building.

THE CODEX

Page 17: Chris everson-wchtx-2010

Function Reference

• The Function Reference portion of The Codex covers tags that are used in the core functionality of WordPress.

THE CODEX

Page 18: Chris everson-wchtx-2010

Theme Development Guide

• The Theme Development Guide is your bible for theme standards and best practices.

• The Theme Development guide also contains the Template File Checklist which is essential if submitting to the WP Theme Directory.

THE CODEX

Page 19: Chris everson-wchtx-2010

Theme Unit Test

• The Theme Unit Test provides test data to check your theme against all data types.

THE CODEX

Page 20: Chris everson-wchtx-2010

WP_Query

Page 21: Chris everson-wchtx-2010

Make The Loop Work For You

• Don’t let default queries define your template.

WP_QUERY

Page 22: Chris everson-wchtx-2010

Potential Uses

• Access query variables

• Modify queries

• Implement multiple loops

WP_QUERY

Page 23: Chris everson-wchtx-2010

Workflow

• Comment your work as you go.

• Maintain clean code throughout the development process.

• Build it all then break it up.

Page 24: Chris everson-wchtx-2010

Deploying Your Theme

• Remove unused/unnecessary code and files.

• Double, triple, quadruple check!

• Public Theme? Submit for WordPress Gallery.

Page 25: Chris everson-wchtx-2010

To Infinity and Beyond

• Continue learning and building your skillset– Theme Options– Plugin Development– Hooks

Page 26: Chris everson-wchtx-2010