我正在使用sportspress插件和菜鸟主题。
我想从播放器中删除姓氏,这可以通过修改过滤器来实现。 我读到修改原始代码很不好,建议创建一个子主题。
这意味着,我应该创建一个新秀的子主题。但是,当我这样做时,只要从正式的wordpress文档中添加基础知识,页面的设计就会改变。
这是我使用的代码:
style.css
/*
Theme Name: Rookie (Sportspress) Child
Description: Rookie (Sportspress) Child Theme
Author: David
Template: rookie
Text Domain: rookiechild
*/
functions.php
<?php
add_action( 'wp_enqueue_scripts', 'my_theme_enqueue_styles' );
function my_theme_enqueue_styles() {
wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );
}
为什么显示的主题与父主题不同?使它看起来相同的最低代码是什么?