WooCommerce child Theme Error
-
Hi I am using wooCommerce for the first time . I am using the storefront theme and trying to add my own child theme but it will not work correctly.
I have added it in my
function storefront_child_scripts() { if ( is_child_theme() ) { wp_enqueue_style( 'storefront-child-style', get_stylesheet_uri().'/custom-child.css', array('parent-style'), '1.0.0' , 'all' ); } }
I also have my custom-child configured as
/* Theme Name: Storefront Theme URI: https://www.woothemes.com/storefront Author: WooThemes Author URI: https://www.woothemes.com Description: Storefront is the perfect theme for your next WooCommerce project. Designed and developed by WooThemes, it features a deep integration with our market leading WooCommerce plugin, several layout & color options to personalise your shop, multiple widget regions, a responsive design and much more. Developers will love it's lean and extensible codebase making it a joy to customise and extend. Looking for a WooCommerce theme? Look no further! Version: 1.5.3 License: GNU General Public License v2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html Text Domain: storefront Tags: black, white, light, two-columns, left-sidebar, right-sidebar, responsive-layout, custom-background, custom-colors, custom-header, custom-menu, featured-images, full-width-template, threaded-comments, accessibility-ready, rtl-language-support */ @import url("../storefront/style.css");
When i inspect it in my browsers it shows in the head but not correctly and the browser cannot seem to find it. I shows as
<link rel="stylesheet" type="/custom-child.css" href="mystyle.css">
As you can see it shows as a wrong type and also the href . I have no idea where mystyle cam from.
Any help would be greatly appreciated .
Thanks You
- The topic ‘WooCommerce child Theme Error’ is closed to new replies.