我在http://eventdepotnj.com上使用WooShop主題併爲其創建子主題。Wordpress兒童主題CSS問題
我做了一個新的目錄/ wooshop獨生子女與此style.css中:
/*
Theme Name: WooShop Child
Description: Child theme for WooShop
Author: Blue Star Multimedia
Template: wooshop
*/
,我增加了一個functions.php文件與此代碼:
<?php
add_action('wp_enqueue_scripts', 'theme_enqueue_styles');
function theme_enqueue_styles() {
wp_enqueue_style('parent-style', get_template_directory_uri() . '/style.css');
}
但是它不工作。
我將我編輯過的header.php和footer.php文件上傳到子主題文件夾以覆蓋常規主題,並且工作正常。但是,當我對style.css文件進行任何更改時,它不會顯示在我的子主題上,它似乎沒有被選中。有任何想法嗎?
如果你直接瀏覽到你的樣式表(http://eventdepotnj.com/wp-content/themes/wooshop-child/style.css?ver=4.1.1)並刷新,你看到你的代碼了嗎? – Hobo
我在那裏看到代碼,但它不是最近更新的版本(我剛更新了一段20px的字體大小以查看它是否工作) –