How to override the “inc” folder (or any folder) in a theme using child theme?

WordPress only looks for the default template files while loading the child theme. So does woocommerce.

Any extra folder or file that exists in your parent theme can not be overridden, unless the developer is using actions and filters that allows you to hook into them. Therefore, a simple require() or include() can’t be overridden by a child theme.

What you can do is to track the template file that is calling the files from the inc folder, and then override those in your theme’s folder. You might need to go as back as functions.php.

For a complete list of default template files, take a look at the template hierarchy.

Leave a Comment

404 Not Found

Not Found

The requested URL was not found on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.