admin管理员组文章数量:1335861
I have a custom post type called 'Inspections'
Doing this, you can access an inspection record by going to example/inspections/inspection-slug-here
However, I want to add some 'sub-pages' if you will:
/inspections/<inspection-slug-here>/sub-page1
/inspections/<inspection-slug-here>/sub-page2
In this case, I would really like sub-page1
and sub-page2
to be templates that I can author in elementor, or something similar.
In a perfect scenario, I would like to pass the details of the parent (inspection-slug-here) to be loaded in this sub section so I can use custom fields or something of the likes.
Is there anything out there that does this? I am using elementor and an elementor templates tool, but cannot find any ways to do what i want.
Thanks!
I have a custom post type called 'Inspections'
Doing this, you can access an inspection record by going to example/inspections/inspection-slug-here
However, I want to add some 'sub-pages' if you will:
/inspections/<inspection-slug-here>/sub-page1
/inspections/<inspection-slug-here>/sub-page2
In this case, I would really like sub-page1
and sub-page2
to be templates that I can author in elementor, or something similar.
In a perfect scenario, I would like to pass the details of the parent (inspection-slug-here) to be loaded in this sub section so I can use custom fields or something of the likes.
Is there anything out there that does this? I am using elementor and an elementor templates tool, but cannot find any ways to do what i want.
Thanks!
Share Improve this question asked May 14, 2020 at 6:21 Barry ChapmanBarry Chapman 816 bronze badges 02 Answers
Reset to default 0If you are interested in using Plugin, and to add PHP code directly into your Elementor, try the following plugin which will enable to add PHP code directly into your Elementor pages.
https://wordpress/plugins/php-everywhere/
You can create a custom Single template and when saving it, set the display conditions to the posts you want.
本文标签: Add custom template 39subpage39 to Custom Post type
版权声明:本文标题:Add custom template 'sub-page' to Custom Post type? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1742397985a2467310.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论