ngrmm Posted September 25, 2015 Share Posted September 25, 2015 pages with the same template have a page-field. i can select multiple pages and they are like tags i output them like this <?php foreach($page->tag as $tags) { echo "<a href='$tags->url'>{$tags->title}</a>"; } ?> the tag-pages ($tags->url) should just show the pages with the certain tag selected. is there a way to filter? where in the documentation do i find something about this. Link to comment Share on other sites More sharing options...
LostKobrakai Posted September 25, 2015 Share Posted September 25, 2015 You can search for the pages with that tag. $taggedPages = $pages->find("template=myTaggedPagesTemplate, tag=$page"); You can find docs about selectors here: http://processwire.com/api/selectors/ And some in depth into in categorizing content can be found here: https://processwire.com/talk/topic/3579-tutorial-approaches-to-categorising-site-content/ 1 Link to comment Share on other sites More sharing options...
ngrmm Posted September 25, 2015 Author Share Posted September 25, 2015 thanks! 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