[英]How can i use one template on different pages in wordpress?
How can I use one template on different pages in WordPress ? 如何在WordPress的 不同页面上使用一个模板 ? If I am using template the WordPress page content is not showing, and if I am not using the WordPress template then only I can see my template.
如果我使用的模板未显示WordPress页面内容,并且如果我未使用WordPress模板,则只有我可以看到我的模板。
You can use one template in different pages in WordPress by assigning the page template option on the right drop down to the template you want to use. 您可以在WordPress的不同页面中使用一个模板,方法是在右侧下拉菜单中将页面模板选项分配给要使用的模板。
if you want to create a custom page and use it as a template in your website you can find detailed steps here , just remember to change the top of your template comment 如果要创建自定义页面并将其用作网站中的模板,可以在此处找到详细步骤,只需记住更改模板注释的顶部即可。
<?php
/*
Template Name: write here your custom name for template
*/
get_header(); ?>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.