Php Wordpress-子页链接恢复到主页
我正在Wordpress上建立一个网站,第一次使用HTML5空白主题。我有一些子页面,我需要添加作为链接从一个主页 在我的主页上有一个标题为“Agency”,在Agency页面中,我有许多图像,这些图像作为链接指向多个(7)子页面- 我已经在我的仪表板上创建了子页面,代理作为父级,因此我得到的第一张图片的链接是…site name/Agency/2k4kproduction。下面是链接的代码。到目前为止,我只转换了两个链接(2k4k和临时链接)——Php Wordpress-子页链接恢复到主页,php,wordpress,Php,Wordpress,我正在Wordpress上建立一个网站,第一次使用HTML5空白主题。我有一些子页面,我需要添加作为链接从一个主页 在我的主页上有一个标题为“Agency”,在Agency页面中,我有许多图像,这些图像作为链接指向多个(7)子页面- 我已经在我的仪表板上创建了子页面,代理作为父级,因此我得到的第一张图片的链接是…site name/Agency/2k4kproduction。下面是链接的代码。到目前为止,我只转换了两个链接(2k4k和临时链接)—— 你对什么产品感兴趣 对于我的文本文件,我
你对什么产品感兴趣
对于我的文本文件,我将它们命名为page-agency-2k4kproduction.php和page-agency-adhoc.php,根据模板层次结构,我认为这是正确的命名约定。但是,当我点击这些链接时,它们会返回到我的主页。我不知道这为什么不起作用,因为我的代理文件/页面与page-agency.php一样工作正常,所以我不确定这为什么不起作用。感谢您的帮助。如果子页面的布局与父页面相同,则没有理由添加不同的模板,只需让它使用
page.php
也许问题来自永久链接,尝试使用默认选项http://www.sample.com/?p=123
@APAD1我尝试了两种方法——page-parent-child.php和as-page-child.php,在这两种情况下,页面都不会加载,只需单击返回page.php(我的主页)。您不需要page parent-child.php
或page-child.php
只要让它使用page.php
。你的主页应该使用index.php
@APAD1,那么就使用child.php?
<div class="twelve columns agencyproducts">
<p>WHAT PRODUCT ARE YOU INTERESTED IN?</p>
<a href="http://localhost:8888/agency/2k4k-production/"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/production.png" alt="Production">
<figcaption>2K / 4K PRODUCTION</figcaption>
</figure></a>
<a href="postproduction.html"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/post-production.png" alt="Post-Production">
<figcaption>POST PRODUCTION</figcaption>
</figure></a>
<a href="2d3danimation.html"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/animation.png" alt="Animation">
<figcaption>2D / 3D ANIMATION</figcaption>
</figure></a>
<a href="http://localhost:8888/agency/adhoc/"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/ADHOC.png" alt="ADHOC">
<figcaption>ADHOC</figcaption>
</figure></a>
<a href="interactive.html"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/interactive.png" alt="Interactive">
<figcaption>INTERACTIVE & PERSONALISED</figcaption>
</figure></a>
<a href="tvadverts.html"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/tv-adverts.png" alt="TV ADVERTS">
<figcaption>TV ADVERTS</figcaption>
</figure></a>
<a href="360video.html"><figure>
<img src="http://localhost:8888/wp-content/uploads/2017/07/360.png" alt="360 Video and VR">
<figcaption>360 VIDEO & VIRTUAL REALITY</figcaption>
</figure></a>
</div>