如何解决WordPress 中的自定义主题不显示任何内容
我已经开始学习 wordpress。 我的自定义主题不显示任何内容。以下是代码。
style.css
/*
Theme Name: My First Theme
Theme URI: http://localhost/wordpress/
Author: Itsmee
Author URI: https://abcd.com
Description: Basic wordpress theme for Sitepoint theme building tutorial
Text Domain: bsimple
Version: 1.0.0
License: GNU General Public License v2 or later
*/
index.PHP
<?PHP
/**
* The main template file
*
* This is the most generic template file in a wordpress theme
* and one of the two required files for a theme (the other being style.css).
* It is used to display a page when nothing more specific matches a query.
* E.g.,it puts together the home page when no home.PHP file exists.
*
* @package My_First_Theme
*/
get_header();
?>
//content HTML here
<?PHP get_footer(); ?>
header.PHP
<?PHP wp_head(); ?>
<head>
<Meta charset="utf-8">
<Meta content="width=device-width,initial-scale=1.0" name="viewport">
<title>Bootstrap Template - Index</title>
<Meta content="" name="description">
<Meta content="" name="keywords">
<!-- Favicons -->
<link href="assets/img/favicon.png" rel="icon">
<link href="assets/img/apple-touch-icon.png" rel="apple-touch-icon">
<!-- Google Fonts -->
<link href="https://fonts.googleapis.com/css?family=Open+Sans:300,400,400i,600,700|Raleway:300,500,500i,700,800,900" rel="stylesheet">
<!-- vendor CSS Files -->
<link href="assets/vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet">
<link href="assets/vendor/icofont/icofont.min.css" rel="stylesheet">
<link href="assets/vendor/animate.css/animate.min.css" rel="stylesheet">
<link href="assets/vendor/font-awesome/css/font-awesome.min.css" rel="stylesheet">
<link href="assets/vendor/nivo-slider/css/nivo-slider.css" rel="stylesheet">
<link href="assets/vendor/owl.carousel/assets/owl.carousel.min.css" rel="stylesheet">
<link href="assets/vendor/venoBox/venoBox.css" rel="stylesheet">
<!-- Template Main CSS File -->
<link href="assets/css/style.css" rel="stylesheet">
</head>
页脚.PHP
<?PHP wp_footer(); ?>
//Footer scripts and other contents
成功创建主题并在后台激活但在前端看不到任何东西,好像主题文件没有渲染。
请帮忙!谢谢。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。