Вот мой файл functions.php:
<?php
function my_theme_enqueue_styles() {
$parent_style = 'oceanwp-style';
wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );
wp_enqueue_style( 'child-style',
get_stylesheet_directory_uri() . '/style.css',
array( $parent_style ),
wp_get_theme('')->get('Version')
);
}
add_action( 'wp_enqueue_scripts', 'my_theme_enqueue_styles' );
?>
А вот мой CSS-файл:
/*
Theme Name: OceanWP Child Theme
Theme URI: t3pranchags.com
Description: OceanWP Child Theme
Author: Christoper Little
Author URI:
Template: oceanwp
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
/* == Add your own styles below this line ==
--------------------------------------------*/
Я работаю на локальном тестовом сайте, и он появляется с тем, что похоже на отсутствие CSS. Моя дочерняя тема активна в WP, но, похоже, она нарушает CSS родительской темы, поскольку CSS вообще не отображается. Я скопировал файл functions.php с другого сайта, которым я управляю, и заменил на мой текущий сайт oceanwp. Есть идеи, что происходит?