Child Theme Check Plugin Helps WordPress Users Navigate Parent Theme Updates

photo credit: Leeroy
photo credit: Leeroy

Child themes have been in use in WordPress for more than seven years and the concept of using them to extend a parent theme is now an established best practice in theme development. The idea is that modifications made in a child theme will not be overwritten when an update is available for the parent theme.

It is generally thought that all edits made in a child theme are future-proof, but this assumes that parent theme authors are developing with child theme users in mind. Indiscriminate changes to markup and selectors can cause serious and unexpected design breaks in child themes.

In a recent post titled “Theme Updates Should Not Induce Panic Attacks,” Leland Fiegel reminds WordPress users that child themes are not totally immune to problems with updates.

“Child themes are certainly a safer alternative to modifying parent themes directly,” Fiegel said. “But characterizing child themes as ‘safe’ while ignoring the risks that irresponsible parent theme updates bring to the table can lead to a false sense of security.”

Fiegel references a WordPress.org support forum request where a user of the popular Avada commercial theme struggled to repair breaking changes that came with theme updates. The situation inspired Fiegel’s post, as it is especially common with WordPress themes loaded with features and marketed as the only solution the customer will ever need.

Child themes are the first line of defense in mitigating problems with updates. When using child themes that make a lot of changes to template files, the Child Theme Check plugin can be useful for reviewing changes in the parent theme after an update to see how they differ from the child theme templates. Once installed, the check can be initiated under the Tools menu.

Child Theme Check automatically runs through all the parent and child theme files and shows the user a status page indicating which files are changed or outdated.

child-theme-check-status

The plugin also shows a diff for each specific file that has changes, highlighting additions and deletions:

child-theme-check-diff

As many theme developers still do not keep a changelog, there’s no easy way to know what changes a user can expect in an update. Running the Child Theme Check plugin after an update from the parent theme can be useful for finding changes that you might want to add to your child theme’s customized files.

In the case of a security update, vulnerabilities can be preserved in the child theme template files if the user has changed them and hasn’t been notified of the update. It can also help track down more cosmetic issues that pop up as the result of an update, such as markup and selector changes. Knowing the file and line where the change was made can drastically cut down on time troubleshooting an update.

If you’re running a highly customized child theme, the Child Theme Check plugin can help bridge the gap to cover the instances where a child theme is not entirely future-proof and help keep your site safer. Download it from WordPress.org to have on hand for the next time you want to review parent theme updates.

11

11 responses to “Child Theme Check Plugin Helps WordPress Users Navigate Parent Theme Updates”

  1. Fantastic plugin! I’ve been using a child theme for my website. The good part is the developer has made it with child themes in mind. However, one of the previous updates broke a few of my formatting elements on the site. Was quick to fix and it could have been worse.

  2. It is a great plugin! But we still need to raise awareness, themes should use a version header, so we are able to compare the versions of the parent and child templates.

    I haven’t checked, but somehow I doubt Avada as an example is using the version header?

  3. Thank you very much for featuring our plugin :)

    But we still need to raise awareness, themes should use a version header, so we are able to compare the versions of the parent and child templates.

    This is true. It would be great if more theme devs would use that @version info in the header. And if you want to help me get this in the TwentySeventeen theme please watch this ticket:
    https://core.trac.wordpress.org/ticket/36972

  4. If we do not want “Theme Updates Induce Panic Attacks”, Theme Check Team should be more flexible. One thing comes to mind – do not force old themes to comply with the new rules that are not required for the security.

    In my example I have two themes with about 13K users. Now I was basically forced to change the text domain. Themes had numerous updates and suddenly I cannot submit update because there is a new rule, that requires text domain be the same as the theme slug. I was told that it is required for the new integration with translation service Glotpress, that I actually do not even use. I was also told that if I will not comply, theme may be dropped from the WP.org in the future.

    So let’s imagine what will happen for the international users after update – some fields will not be rendered in their language. Now it basically means that every one using a child theme (who cares if they have skills…) will have to go through functions.php and other files and change the text domain.

    It is sad, but that’s the price to be listed on WP.org…

  5. I have tested it on some sites and it worked. But seems it sometimes break on sites with Genesis framework installed. After installing the plugin, the complete admin panel’s link becomes underlined. Might be conflict with some plugin. I will update once I find it out.

Newsletter

Subscribe Via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

%d bloggers like this: