Wordpress:访问存储在主题文件夹中的子文件夹中的模板

Wordpress: Accessing templates stored inside a subfolder in the themes folder

我目前正在使用 twentyfifteen 主题来创建我的应用程序。现在,在 twentyfifteen 主题文件夹中,我有另一个名为 tuto 的文件夹,里面是我要使用的模板,名为 oauth.php。这里有几个屏幕截图可以概述我的项目的文件结构:

现在,为了访问我的 oauth.php 文件,我尝试访问以下 link:

http://localhost/wordpress/tuto/oauth.php

但是,我得到的是 Object not found! 页面。

我刚开始使用 Wordpress,希望能提供一些帮助,帮助我了解如何访问存储在主主题文件夹中的子文件夹中的模板。

登录到管理并创建新页面。在 select 模板部分的右侧,您可以看到您创建的模板。 select 您创建的模板并创建新页面。然后您只需访问此页面即可访问您的创建模板。

刚看完

https://developer.wordpress.org/themes/template-files-section/page-template-files/page-templates/