I don’t know if anyone is currently working on or will be adding a kind
of menu functionality to Radiant. The idea being that there are
navigational element necessary to navigate the site’s content areas.
The idea here is that for content, it automatically creates a
list
that you can manipulate to your liking.
So:
/ – root
— Home
— About Me
------- About the Site
— Database
------- Sub Section One
--------- Page One
--------- Page Two
------------ Sub Page One
— Contact Me
This would be automatically created inside a tag, possibly something
like <r:menu /> which would have options to exclude pages and etc and
style to your liking, so only page relevant to the area show up.
I don’t know if anyone is currently working on or will be adding a kind
of menu functionality to Radiant. The idea being that there are
navigational element necessary to navigate the site’s content areas.
The idea here is that for content, it automatically creates a
list
that you can manipulate to your liking.
So:
/ – root
— Home
— About Me
------- About the Site
— Database
------- Sub Section One
--------- Page One
--------- Page Two
------------ Sub Page One
— Contact Me
This would be automatically created inside a tag, possibly something
like <r:menu /> which would have options to exclude pages and etc and
style to your liking, so only page relevant to the area show up.
I hope I am getting my idea across.
I am in need of something very similar to this and will probably be
tackling the problem sometime in the week. Have you looked at the
sitemap howto? That may be a good place to start.
Seancribbs also showed some interest in producing such a tag in IRC the
other day although I’m not sure if anything came from that in the end.
I don’t know if anyone is currently working on or will be adding a
kind
of menu functionality to Radiant. The idea being that there are
navigational element necessary to navigate the site’s content areas.
I am in need of something very similar to this and will probably be
tackling the problem sometime in the week. Have you looked at the
sitemap howto? That may be a good place to start.
I’ve thought about doing something similar, but I just haven’t had
the time to get to it. I was thinking to make a tag very similar to
the <r:navigation /> tag, but instead of giving it a list of titles
and paths, give it a parent page, eg:
<r:menu parent="/root/path" />
and it uses the <r:selected /> and other navigation tags.
I’ve thought about doing something similar, but I just haven’t had
the time to get to it. I was thinking to make a tag very similar to
the <r:navigation /> tag, but instead of giving it a list of titles
and paths, give it a parent page, eg:
<r:menu parent="/root/path" />
and it uses the <r:selected /> and other navigation tags.
Hmm, that’s another possibility. I may try to tackle this today if I can
get my head around how to best deal with the multiple levels and
expanding the current section correctly.
On our website, I implemented submenus the following way:
Create a submenu snippet:
This renders an unordered list of links to all children of a page. If
some pages are to be excluded, you can do this by adding some
<r:unless_url/> markup.
Create a content part “submenu” on each first levelpage that has
children:
This calls the above snippet with the current page selected so that the
snippet will iterate over its children and render its submenu.
Include the content part in your layout
<r:content part=“submenu” inherit=“true”/>
The “inherit” attribute makes sure the submenu will be used on all child
pages unless overridden.
It’s a quick and rather non-DRY solution because you have to define the
content part on each first level page and to manually enter the page
title there, but from there everything works automatically. Highlighting
etc. can be done with CSS - if you are interested, I can post some code.
Note the smart way of including page-level CSS by just creating a
‘stylesheet’ Page Part in the Admin Interface, but if no part of that
name exists then the page does now show any signs of it. (Just added
to Receipes on Wiki
I also want to follow the <r:if_child> to the secondarynavigation so
instead of