My child theme does not load the parent styles
-
Dear all,
I tried to make a child theme in order to make css changes, but I can not get it. I tried to explain everything I’ve made:The web I am working in is this one.
The parent theme is called oblique
I follow the steps explained everywhere:
– I create a new folder in wp-content/themes/ called oblique-hijo
– I create a style.css inside the folder oblique-hijo
– I put the following in the style.css:/* Theme Name: Oblique Hijo Theme URI: https://www.lucversleijen.nl/themes/oblique-demo/ Author: Fernando Diaz Author URI: https://www.dos56.es Description: Para hacer cambios en tema Oblique Version: 1.0 License: GNU General Public License v2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html Text Domain: oblique Tags: one-column, two-columns, left-sidebar, right-sidebar, fluid-layout, custom-menu, full-width-template, theme-options Template: oblique */ @import url("../oblique/style.css");
– I activate the child theme.
– And the result is what you can see here. All styles are lost.I have to say that is not the first time I make a child theme and with other themes it worked properly.
I tried to make what is explained in the codex, creating a functions.php in child theme folder and write inside this code:
add_action( 'wp_enqueue_scripts', 'theme_enqueue_styles' ); function theme_enqueue_styles() { wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' ); }
and same result.
I have checked that if I write css code in the style.css of the child theme, it is showed in the web. So the style.css is ok, but the import of the parent styles is not working.
Note: The author of the theme is not answering in the support available.
Please, ?some idea?
Thanks a lot.
- The topic ‘My child theme does not load the parent styles’ is closed to new replies.