Pro Child Theme

I’ve added a Pro child theme to my site’s WordPress (I need to make changes to core PHP files that need to persist for SEO purposes, so can’t rely on the WP Admin’s Theme Editor nor a plugin). Despite it being installed successfully, I’m reluctant to activate it. Will the child theme inherit the current styles and setup of our core Pro theme? I am assuming that is what the PHP code is designed to do here? It looks fine when I Preview it, I’m just worried about any kind of breaking changes that can occur. But Pro is Pro, right?

Hi @agorder,

Thank you for reaching out to us. Child themes allow you to modify, or add to the functionality of that parent theme instead of modifying the core theme files directly and inherits all the styles and setup of the parent theme. The problem with modifying core theme files is that your changes are in danger of being overwritten if and when you update the theme to the latest version down the road. This is obviously an undesirable outcome, especially if you’ve made dozens of adjustments throughout the theme.

In the context of using the X and Pro themes the only time, you need to utilize a child theme is when you want customization inside the PHP files of the theme itself or use the WordPress actions and filters to achieve custom functionality.

To learn more please see https://theme.co/docs/child-themes

Hope this helps!

What I’m trying to do is do away with WordPress’s h1 tag for blog post titles. Our Pro theme already gives us one, and it’s not good to have two on the same page. So my plan is to modify the WordPress PHP file that does this, which I am assuming is part of the Pro theme files. I’m reviewing the article Best Practices | Themeco Docs and having a little trouble understanding how to go about it. So I basically have to replicate the directory structure in the child theme with the modified file? And how would I go about applying the changes to the actual site? Do I zip the child theme and add it again from the WP Admin?

Hi @agorder,

After you installed the PRO child theme, please activate it. Yes PRO child will inherit its parent all functionalities, styling, etc.

Now, please follow the Best Practices when you modified a file. That means you need to copy the original file from the parent theme, paste it on the child theme, yes, in the same directory (create the directory if it does not exist)

I’m not sure, which h1 you need to remove/modify, but I think this thread would help or give you an idea of how to use the child theme.

I advise that you use FTP when editing a PHP file because editing it from the admin dashboard can get you lock out from your site if there is an error.

Hope it helps,
Cheers!

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.