0

我不断收到错误消息,无法自定义 TheGem 的样式,因为无法修改文件“/home2/stargbb9/public_html/wp-content/themes/thegem-child/css/custom.css”。请检查您的服务器设置。然后单击“保存更改”按钮。

然后我编辑了 .css 和函数文件,但它仍然让我在保存更改后输入我的 FTP 详细信息并直接导致错误。

---- (style.css)

    /*
    Theme Name: TheGem Child
    Description: Multi-Purpose Wordpress Theme
    Author: Codex Themes.
    Theme URI: http://codex-themes.com/thegem/
    Author URI: http://codex-themes.com/thegem/
    Template: thegem
    Version: 1.0
    Tags: one-column, two-columns, left-sidebar, right-sidebar, responsive-layout, custom-background, custom-colors, custom-header, custom-menu, featured-images, flexible-header, full-width-template, theme-options, translation-ready, dark, light
    License: GNU General Public License
    License URI: license.txt
    */

--- functions.php

    <?php
    add_action( 'wp_enqueue_scripts', 'my_theme_enqueue_styles' );
    function my_theme_enqueue_styles() {

        $parent_style = 'parent-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')
        );
    }
    ?>
4

0 回答 0