Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress How to Make a Website with WordPress Customizing WordPress Themes How to Make Child Themes

Labeling Files

I was attempting to change screenshot.png with another file name, storefront.png and it did not work.

However, when I changed storefront.png to screenshot.png, the image displayed correctly within the themes admin panel.

  • Therefore, is it necessary for theme images to be named "screenshot.png"?

Second, I also had problems with getting my child template to display correctly after applying the child template.

I copied and pasted and refreshed the screen multiple times and it did not change. But after about 10 minutes, it was resolved as I continued to fiddle with it. However, I have no idea why it all of the sudden worked.

  • So are there specific naming/syntax conventions that need to followed exactly for it to work?

Thanks, Phou

1 Answer

Raymon Oleaga
Raymon Oleaga
19,298 Points

Absolutely, WordPress has specific naming convention for certain things. Example: screenshot.png most be named this way in order to display. Also, page templates have naming conventions. You can find all this information in the wordPres codex or you can watch some of the videos in the WordPress development course, they explain everything very well.

About your child theme is hard to say without knowing specifics... All I can say that to start a child theme first you have to:

1. create a new theme folder under the "wp-content/themes" folder
2. Create a new CSS file in the child theme folder and name it style.css.
3. Paste the sample code below in the style.css file.

 /*
Theme Name: Child Theme Name
Description: Give a short description
Author: Your name
Template: give it a name
*/

hope this helps!