Job a11n
(@jobthomas)
Automattic Happiness Engineer
Hey @fbarret – without seeing the files, it’s very difficult to see what exactly is happening, but let’s try to find a few pointers.
If your child theme functioning correctly? Without adding any other files, is your child theme active and looking exactly like Storefront?
Have you created the right folders? Overrides for WooCommerce specifically, should be under wp-content/themes/your-child-theme/woocommerce/templates/.
Hello Job, Thank for your answer.
I can’t show you the project that is in developpement and confidential for now.
All works correctly, the child theme is clean and with only a few files.
Yes, as I said, I followed WooCommerce instructions and created directories and files with correctly named, as described here: https://docs.woocommerce.com/document/template-structure/
The problem is that apparently Storefront overides the html structure of the WooCommerce plugin with its storefront-woocommerce-template-functions.php file for ex. Storefront complicates strongly the customization and it is rather annoying because of the wasting time induced…
For example, what is the best method under these conditions to simply modify these content framing tags:
<div id=”primary” class=”content-area”><main id=”main” class=”site-main” role=”main”>
…to add/delete an attribute, add a tag…?
Such little things that would save me from producing masses of CSS or JQuery scripts.
Regards,
François
@fbarret For situations like this, I would recommend you use this handy little plugin called Real-Time Find and Replace:
https://ww.wp.xz.cn/plugins/real-time-find-and-replace/
How this works is that the plugin will do a search and replace after the HTML has been rendered, which means that you can search for <div id="primary" class="content-area"><main id="main" class="site-main" role="main"> and replace with <div id="primary"><main id="main">, for example.
That would save you the hassle of writing template files for smaller tweaks.
I hope that helps!
Hello Fernando,
Thank you very much for that information. The plugin seems very interesting and probably useful in many cases.
I’ll try it soonly.
Regards.