Hi
Im having problems trying to get this resource to work, i dont know if this is the correct way to do this. but I would like to generate a menu list from a list of given page ID's. What I have so far is:
[[!pdoResources? &includeTVs=`title,id` &tpl=`get-glossary-row` &parents=`24,25,26,27,28`]]
my chunk contains:
<li>
<a href="[[++site_url]][[~[[+id]]]]">
[[+tv.title]]
</a>
</li>
is this the correct way, am i doing something wrong?
-
☆ A M B ☆
- 24,524 Posts
Do you actually have Template Variables named "title" and "id"?
If you mean the resources' pagetitle and id, those are simply accessed with [[+pagetitle]] and [[+id]], and no property &includeTVs. That's only necessary if you want to use Template Variables besides the regular resource fields.
Hi
Thanks for your response, yes I do have a TV called Title. the problem im finding is that i cant get it to show the specificed pages. the parent page is the (web) home page, I have specific documents I want to show in the menu. these documents are only 1 level from the home page and do not contain any child pages.
-
☆ A M B ☆
- 24,524 Posts
The &parents property tells it what resources to use as parents, it will try to display the children of those resources. So if your parent is #1, the &parents=`1` would get all of its children. As Jako says, if you are going to specify what resources you want in the list, then set &parents=`-1` to tell it to ignore that property and just list the ones you have in &resources.