0
나는 매우 혼란스럽고 도움이 필요합니다! 저는 22 개의 16 개의 아이 테마를 만들었고 모든 것이 완벽하게 작동했습니다. 아이 스타일은 부모의 스타일보다 우선합니다. 그런 다음 갑자기 WP 관리자의 메뉴를 약간 변경했을 때 자식 CSS가 지배적으로 중단되었습니다. 내가 만든 모든 하위 테마에서이 후 부모 스타일은 항상 하위 CSS를 재정의합니다. 여기에 나는 자식 CSS에 넣은 코드가있다.Wordpress 어린이 테마 CSS의 크래시
/* Theme Name: Proservice_2016
Description: Proservice Theme
Author: VB
Template: twentysixteen
Version: 1.0.0
Tags: light, dark, two-columns, right-sidebar, responsive- layout, accessibility-ready
Text Domain: proservice
*/
@import url("../twentysixteen/style.css");
또한 functions.php에 다음 코드 여기
<?php
function parent_css_theme_style() {
wp_enqueue_style('parent-style', get_stylesheet_directory_uri().'/style.css');
}
add_action('wp_enqueue_scripts', 'parent_css_theme_style');
add_action('wp_enqueue_scripts');
?>
'get_stylesheet_directory_uri()'는 부모 테마에 대한 URI를 반환하지 않습니다 ... [현재/자식 테마의 디렉토리 URI를 반환합니다] (https://codex.wordpress.org/Function_Reference/get_stylesheet_directory_uri). – rnevius
functions.php 파일에서 get_template_directory_uri()를 사용하여 get_stylesheet_directory_uri()를 변경하십시오. https://codex.wordpress.org/Child_Themes –
get_template_directory_uri()로 변경했으나 작동하지 않습니다. 부모 CSS는 자식 테마에 대해 완벽하게 작동하지만 자식 CSS를 무시하고 내 변경 사항 중 아무 것도 표시되지 않습니다. –