2hoch11 Posted January 14, 2020 Share Posted January 14, 2020 I am trying to get this site structure: … /projects/ (is rendered, is in nav menu) /projects-folder/ (not rendered, not in nav menu) /projects-folder/project1 (rendered, not in nav menu) /projects-folder/project2 (rendered, not in nav menu) /projects-folder/project3 (rendered, not in nav menu) … How can I create the "projects-folder"? Do I need a "folder" or a "blank"-template. Or is there any better solution? Link to comment Share on other sites More sharing options...
flydev Posted January 14, 2020 Share Posted January 14, 2020 If I understand, this will help you : Check this function : https://processwire.com/api/ref/functions/wire-render-file/ A blog introduction: https://processwire.com/blog/posts/processwire-2.5.2/#new-wirerenderfile-and-wireincludefile-functions A example approach : https://marcus.io/blog/contextual-components-php Search Helper for forum posts: https://www.google.com/search?q=wirerenderfile+partial Link to comment Share on other sites More sharing options...
3fingers Posted January 14, 2020 Share Posted January 14, 2020 ..or if you mean by "folder" a parent container within the tree structure then yes, you need to create a blank template (without a template file) with just a "title" field (since it's the default and mandatory). 2 Link to comment Share on other sites More sharing options...
2hoch11 Posted January 14, 2020 Author Share Posted January 14, 2020 Thank you flydev. My question is about how to create a folder, not how to render the files. Link to comment Share on other sites More sharing options...
dragan Posted January 14, 2020 Share Posted January 14, 2020 I'm not sure I understand the question, but I guess by "folder" you mean "a URL structure that doesn't exist neither as physical folder on disk nor in the PW page-tree". If that's what you're after, you can enable URL segments in home (page id 1), and then go from there. There are plenty of forum threads with examples. It's really simple and straightforward (no need to mess around with .htaccess rewrite rules etc.) https://processwire.com/docs/front-end/how-to-use-url-segments/ 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now