How to Create a Child Theme and Why You Should Use One
I have decided to finally write and publish a new useful article about the Divi theme on my blog. I hope all of you – my audience and my subscribers will find this article helpful. And I will keep it brief, as I don’t like reading long articles and I think most people don’t like that either.
If you are using some custom code on your Divi website – e.g. you have changed the footer links text in the footer.php file or you have edited the functions.php file of the Divi theme, it is highly recommended to use a child theme, so that when you update Divi to a newer version you won’t lose your custom codes. Below you can read my quick tutorial on how to create a child theme.
To create a child theme, just create a new folder, e.g. divi-child and place a file style.css into it. You can create this style.css file simply in a text editor like Wordpad or Notepad and then just rename this new .txt file to style.css. Into this style.css file place the following code (you can copy and paste it right from here):
Theme Name: Divi child theme
/* PLACE YOUR CUSTOM CSS CODE BELOW THIS LINE */
Please note: If you copy and paste the above code, sometimes the “” characters are not copied properly, so your child theme might not work. In such case just rewrite these 2 characters (“”) manually and it will work.
After that if you are using some custom code in any file of the Divi theme, let’s say I have some custom links in the footer.php file, so then you need to place this footer.php file with the custom code to the divi-child folder.
The next step is to upload the whole divi-child folder via FTP into your themes directory and activate the child theme in the WP admin panel. You can use FileZilla for FTP uploading or CoffeeCup Free FTP if you are using BlueHost. Both of these FTP managers are free.
And that’s it, you are all set with your Divi child theme.
I’m also going to write on some new Divi and/or WordPress related topics more often, so if you have not subscribed to my blog yet, feel free to do so, so that you do not miss any of my articles. You can like my Facebook, Twitter, Google+ page (you will find links at the bottom on the right) or you can also subscribe to my mailing list here – I promise I will not be sending you any spam, I will only email you when I publish a new article, so that you do not miss even a single one.