On 12 Jan 2009, at 20:43, Paul Ingles wrote:


<r:children:each>
<li <r:if_self> class="selected"</r:if_self><r:unless_self> class="item"</r:unless_self>>
     <a href="<r:url/>"><r:title /></a>
   </li>
</r:children:each>

I think what you need to do is wrap the above section of code in a <r:find/> tag. If the "Items Intro" has the url: /items you would do something like:

<r:find url="/items">
   <r:children:each>
<li <r:if_self> class="selected"</r:if_self><r:unless_self> class="item"</r:unless_self>>
        <a href="<r:url/>"><r:title /></a>
      </li>
   </r:children:each>
</r:find>

That way, it will always find the children of the "Items intro" page, even if the page you are on *is* a child of "Items intro".

You might need to tinker with the if/unless_self conditions to apply the appropriate classes.

If you find yourself wanting to work with sibling pages, instead of child pages, then check out the sibling_tags extension:

        http://github.com/nelstrom/radiant-sibling-tags-extension/tree/master

This is useful, for example, if you want to provide "Next" and "Previous" links.

Hope this helps,
Drew
_______________________________________________
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant

Reply via email to