WordPress Child Themes June 23rd, 2014

Use child themes to avoid losing changes when themes are updated by their vendors.

  1. Create a new theme folder with the same name as its parent, plus “-child” appended to it
  2. Create a style.css file with at least the following three required lines…
    1. Theme Name (ex.Theme Name: Twenty Fourteen Child) … NOTE: No spaces allowed before colon, but after is fine for code alignment
    2. Template (ex.Template: twentyfourteen) … NOTE: No spaces allowed before colon, but after is fine for code alignment
    3. The ‘@import url‘ line (ex.@import url(“../twentyfourteen/style.css”);)
  3. (Optional) Create any template files for which you desire to override its equivalent file in the parent theme directory
    1. Exception: If you create a functions.php file it will be loaded right BEFORE the parent theme’s functions.php