Title: creating child theme
Last modified: January 9, 2020

---

# creating child theme

 *  [greencrest](https://wordpress.org/support/users/greencrest/)
 * (@greencrest)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/creating-child-theme-15/)
 * I’m trying to create a child theme based on twenty twenty and want to use the
   full width styles. However, when I base it off the singluar.php file, its using
   the thin styles, not the full width. I can’t locate how the theme is adding the
   class name to set the width. Anyone familiar enough with the twenty twenty theme
   to know where I can set the content width to use the full width styles? I’m gone
   through the functions file as well as the template files and can’t determine 
   how this is dynamically set.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fcreating-child-theme-15%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 5 replies - 1 through 5 (of 5 total)

 *  [Jarret](https://wordpress.org/support/users/jarretc/)
 * (@jarretc)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/creating-child-theme-15/#post-12310077)
 * It adds the code for the full width here:
 * [https://themes.trac.wordpress.org/browser/twentytwenty/1.1/inc/template-tags.php#L641](https://themes.trac.wordpress.org/browser/twentytwenty/1.1/inc/template-tags.php#L641)
 * Which is based upon if the template for the post is set to Full Width or not.
 *  Thread Starter [greencrest](https://wordpress.org/support/users/greencrest/)
 * (@greencrest)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/creating-child-theme-15/#post-12311899)
 * Thanks. I’m assuming I just create a template-tags file within the child theme
   folder with what I want to modify?
    -  This reply was modified 6 years, 4 months ago by [greencrest](https://wordpress.org/support/users/greencrest/).
 *  Thread Starter [greencrest](https://wordpress.org/support/users/greencrest/)
 * (@greencrest)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/creating-child-theme-15/#post-12311982)
 * I duplicated the template-tags.php file and added this code:
 *     ```
          	// Check whether the current page has full-width content.
       	if ( is_page_template( array( 'templates/front-page.php' ) ) ) {
       		$classes[] = 'has-full-width-content';
       	}
       ```
   
 * But the home page isn’t adding the template-full-width class to the home page.
   Any idea what I’m doing wrong?
 *  [Jarret](https://wordpress.org/support/users/jarretc/)
 * (@jarretc)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/creating-child-theme-15/#post-12314613)
 * There isn’t a front-page.php template unless you added one and have that set 
   as the template for your homepage. You would probably have to try something like
   the `is_home()` function and add the class that way.
 *  Thread Starter [greencrest](https://wordpress.org/support/users/greencrest/)
 * (@greencrest)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/creating-child-theme-15/#post-12353656)
 * Thanks.
    -  This reply was modified 6 years, 3 months ago by [greencrest](https://wordpress.org/support/users/greencrest/).

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘creating child theme’ is closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/twentytwenty/3.0/screenshot.png)
 * Twenty Twenty
 * [Support Threads](https://wordpress.org/support/theme/twentytwenty/)
 * [Active Topics](https://wordpress.org/support/theme/twentytwenty/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/twentytwenty/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/twentytwenty/reviews/)

## Tags

 * [child theme](https://wordpress.org/support/topic-tag/child-theme/)
 * [Themes](https://wordpress.org/support/topic-tag/themes/)
 * [twenty twenty](https://wordpress.org/support/topic-tag/twenty-twenty/)

 * 5 replies
 * 2 participants
 * Last reply from: [greencrest](https://wordpress.org/support/users/greencrest/)
 * Last activity: [6 years, 3 months ago](https://wordpress.org/support/topic/creating-child-theme-15/#post-12353656)
 * Status: not resolved