I wanted to create a child theme on my new Wordpress site.

I followed the instructions on the first part of this site: http://codex.wordpress.org/Child_Themes

After doing everything AFTER "How to Create a Child Theme" and before "Template Files", I'm getting the following error message:

Fatal error: Cannot redeclare twentyfifteen_widgets_init() (previously declared in /home/username/public_html/wp-content/themes/twentyfifteen-child/functions.php:142) in /home/username/public_html/wp-content/themes/twentyfifteen/functions.php on line 141

(Here, I'm replacing my actual username with the word "username")

I'm not sure really where to start. I followed the directions to a T and am even using the same theme...

closed as off-topic by Michael, Pieter Goosen, Mark Kaplun, cybmeta, shea Mar 21 '15 at 1:42

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions that are too localized (such as syntax errors, code with restricted access, hacked sites, hosting or support issues) are not in scope. See how do I ask a good question?" – Michael, Pieter Goosen, Mark Kaplun, cybmeta, shea
If this question can be reworded to fit the rules in the help center, please edit the question.


Your child theme's functions.php file should be an empty file to which you can add code specific to your child theme. It appears you have copied the functions.php file from the parent theme instead.

See this note about functions.php in Child Themes:

Unlike style.css, the functions.php of a child theme does not override its counterpart from the parent. Instead, it is loaded in addition to the parent’s functions.php. (Specifically, it is loaded right before the parent’s file.)

Not the answer you're looking for? Browse other questions tagged or ask your own question.