Home › Forums › WoodMart support forum › I updated the theme today and it seems to have broken my css
I updated the theme today and it seems to have broken my css
- This topic has 9 replies, 2 voices, and was last updated 8 months, 1 week ago by
Artem Temos.
-
AuthorPosts
-
November 25, 2024 at 8:17 pm #615754
fotovivaParticipantSince the upgrade none of my css loads – please help!
Have cleared cache and refreshed permalinks
-
This topic was modified 8 months, 1 week ago by
fotoviva.
November 25, 2024 at 10:11 pm #615787
Artem TemosKeymasterHello,
Please disable any plugins not directly related to our theme and provide us with your admin access details. We will log in to your dashboard and investigate the issue. Please ensure that you only keep the following plugins that are necessary for our theme to work correctly:
– WoodMart core
– WooCommerce
– Elementor/WPBakery Page BuilderThank you in advance.
November 26, 2024 at 12:56 am #615816
fotovivaParticipantThanks
November 26, 2024 at 9:59 am #615877
Artem TemosKeymasterWe just switched to the parent theme and it works correctly. Please check your website now.
November 26, 2024 at 12:23 pm #615989
fotovivaParticipantI appreciate your swift reply! I have a staging version at https://www.staging3.fotoviva.co.uk which is using the same child theme and it works fine. I have run any changes to the child theme through a code checker and it comes back validated, but the only difference is that the staging version of the site is not using the updated theme. So it appears something in the update has messed things up. Any ideas?
November 26, 2024 at 12:26 pm #615995
Artem TemosKeymasterAs we can see, you have some customizations made in the child theme. We don’t know exactly what is wrong but the fact is that they cause this problem. You can try to restore our original child theme and see that it works correctly without your custom code.
November 26, 2024 at 7:22 pm #616232
fotovivaParticipantThanks. The new child theme I downloaded seems to have a simplified code in the functions file:
<?php
/**
* Enqueue script and styles for child theme
*/
function woodmart_child_enqueue_styles() {
wp_enqueue_style( ‘child-style’, get_stylesheet_directory_uri() . ‘/style.css’, array( ‘woodmart-style’ ), woodmart_get_theme_info( ‘Version’ ) );
}
add_action( ‘wp_enqueue_scripts’, ‘woodmart_child_enqueue_styles’, 10010 );compared to my old one:
<?phpadd_action( ‘wp_enqueue_scripts’, ‘woodmart_child_enqueue_styles’, 1000 );
function woodmart_child_enqueue_styles() {
$version = woodmart_get_theme_info( ‘Version’ );if( woodmart_get_opt( ‘minified_css’ ) ) {
wp_enqueue_style( ‘woodmart-style’, get_template_directory_uri() . ‘/style.min.css’, array(‘bootstrap’), $version );
} else {
wp_enqueue_style( ‘woodmart-style’, get_template_directory_uri() . ‘/style.css’, array(‘bootstrap’), $version );
}wp_enqueue_style( ‘child-style’, get_stylesheet_directory_uri() . ‘/style.css’, array(‘bootstrap’), $version );
}
Has this been updated? Perhaps this was the cause. I have added my edits to the new one and it works fine.
November 26, 2024 at 8:09 pm #616271
Artem TemosKeymasterThe new child theme was introduced 4 years ago. It’s strange that you had an outdated version there. Anyway, we are glad that you sorted it out. Feel free to contact us if you have any further questions.
November 26, 2024 at 11:57 pm #616328
fotovivaParticipantThanks, I also have header.php in the child folder, should I update to the most recent?
November 27, 2024 at 9:12 am #616392
Artem TemosKeymasterYes, you need to copy this file from the latest version and then add your custom code if needed.
-
This topic was modified 8 months, 1 week ago by
-
AuthorPosts
- You must be logged in to create new topics. Login / Register