Setting up a Child theme – functions.php
-
I’m trying to set up a child theme. I’ve copied the content of the wp-content/themes/twentyseventeen folder into the wp-content/themes/twentyseventeen-child. I understood the functions.php of the child theme should not be the same as the parent version. I’ve tried to edit the functions.php in the child theme by just using the <?php tag.
I noticed the functions.php file in my parent theme lost it’s code as well (minus the <?php tag) and that my site broke down. I’ve put back the master code but how can I edit my functions.php file in my child theme without creating the same edits in my parent theme file?
I understood that the functions.php gets loaded differently than for example the style.css. I’m
fairlynew to child themes, but I’ve read the basics for the past two hours. Is it normal to have the code from the functions.php child theme file being copied automatically into the parent theme version? I feel like I’m doing something wrong/missing something. Should I start completely over by creating just a style.css and functions.php with only<?php
? How do I prevent this gets copied into my parent files?Hope anyone can help this newbie ?? Thanks a lot! Regards, Ilse.
- The topic ‘Setting up a Child theme – functions.php’ is closed to new replies.