我在启动wordpress 2014主题的儿童主题时遇到了困难。我创建了一个二十四个孩子的文件夹。我有一个style.css
1 /*
2 Theme Name:Twenty Fourteen Child
3 Version: 1.0
4 Theme URI: link
5 Description: A basic starter child theme for Twenty Fourteen
6 Author: Tim
7 Author URI: link
8 Template: twentyfourteen
9 License: GPL
10 License URI: ...
11 */和一个functions.php
1<?php
2 add_action( 'wp_enqueue_scripts', 'enqueue_parent_styles' );
3 function enqueue_parent_styles() {
4 wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css');
5 }我正在运行另一个具有相同主题和相同代码的wordpress站点,它运行得很好。这两个网站都安装在子目录中,来自style.css的模板名与父主题的目录名相匹配。基本上我只是复制了这两个文件。
当我激活子主题时,菜单结构就被破坏了。左边和顶部都有一个菜单,但现在它们都合并到了顶部菜单中。有人知道这里会有什么问题吗?
发布于 2015-02-11 09:15:23
如果你已经设置好你的主题,然后激活你的孩子主题,你必须重新分配你的菜单的真实外观->菜单的。
https://stackoverflow.com/questions/28448983
复制相似问题