views:

60

answers:

3

This is somewhat a subjective question.

Noticed themes like thematic and carrington use hooks to display their themes.

Trying to figure out which works best for a more efficient workflow.

Which seems more efficient at theming? Trying to weigh in the cons and pros of hooks vs. just including static files.

+4  A: 

By all means, use the hooks. This is more efficient, and allows your theme to play nice with a variety of widgets and add-ins that also depend on the template hooks. Using static includes will make your template much less flexible overall, and opens you up to possible breakage as changes are made to the WordPress backend.

JSBangs
Booyah, JS Bang nailed it.
hsatterwhite
I find debugging a little more difficult when reliable with hooks (maybe i'm wrong here. I'm not that savvy in php). What's a good dead simple way to isolate issues by line (file name) ? firephp?
Chris J. Lee
+1  A: 

If you work with Thesis, this plugin WordPress › Thesis OpenHook « WordPress Plugins is very interesting from a hook standpoint and what could possibly be done with other frameworks for both end users and developers.

songdogtech
+1  A: 

Hooks and include()s are really intended for two completely different purposes. Includes statically bring additional content into your theme, while hooks allow plugins and your theme's functions.php to add content on-the-fly. With the new-ish additions to WordPress of child themes, hooks also allow said children to add content to your theme without modifying the core files.

All-in-all, this makes your theme more future-proof and a much easier recommendation when it comes time to consider theme frameworks to base a site upon.

ZaMoose