Child Themes and the Template Hierarchy

Sponsored · SiteGround - Reliable hosting with speed, security, and support you can count on. →
Caleb Burks
November 05, 2016

Child Themes and the Template Hierarchy

Caleb Burks

November 05, 2016

Annual Pro sale · Save $30

Have presentations of your own?

Share with private links, password protection, and more control over your work.

Transcript

42 slides
  1. About Me » Caleb Burks » WC Ninja at Automattic

    » Loves Gummy Bears » Tweets at @WPprodigy
  2. Style.css /* Theme Name: My Theme Theme URI: http://awesometheme.com Author:

    Caleb Burks Author URI: http://author.com Description: Blah Blah License: GNU General Public License v3 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Text Domain: storefront */
  3. Main Templates: Page » front-page.php - static homepage » page.php

    - backup for front-page.php » singular.php - Fallback
  4. Custom Templates: Archives » category-$slug.php » category-$id.php » tag-$slug.php »

    tag-$id.php Applies to authors, taxonomies, and CPT's as well.
  5. style.css /* Theme Name: Twenty Fifteen Child Theme URI: http://example.com/twenty-fifteen-child/

    Description: Twenty Fifteen Child Theme Author: John Doe Author URI: http://example.com Template: twentyfifteen Version: 1.0.0 License: GNU General Public License v2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Tags: light, dark, two-columns, right-sidebar, responsive-layout, accessibility-ready Text Domain: twenty-fifteen-child */ Template is important.

More Decks by Caleb Burks

Other Decks in Programming