Questions on navigation

33 views
Skip to first unread message

Andry

unread,
Nov 9, 2011, 5:09:11 AM11/9/11
to RedDot CMS Users
Hi guys!

I'd like build an automated landing page where the page displays
submenus and two four sub sub menus. e.g. the current menu levels:

0 Home
1 Housing & living
1.0 Accommodation
1.1 Transport
2 Careers
2.0 Career Centre
2.1 Field work education
2.2 Mentors

And so displays in the home page:

Housing & living
- Accommodation
- Transport

Careers
- Career Centre
- Field work education
- MORE

I can get the first level to load by using lst_Navigation. But how do
I get each sub page's lst_Navigation?

Can anyone please help me?

Thank youuu!

Andry

Gavin Cope

unread,
Nov 9, 2011, 6:28:55 AM11/9/11
to reddot-c...@googlegroups.com

Look at using subindexes and Navigation Manager to achieve the desired result. There's probably a code snippet in the archives somewhere. I'm on my phone atm so don't have access to my code library.

Cheers,

Gavin

--
You received this message because you are subscribed to the Google Groups "RedDot CMS Users" group.
To post to this group, send email to reddot-c...@googlegroups.com.
To unsubscribe from this group, send email to reddot-cms-use...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/reddot-cms-users?hl=en.

Mark Radford

unread,
Nov 9, 2011, 9:44:15 AM11/9/11
to RedDot CMS Users
Which version of RedDot are you using, Andy?

Joel Kinzel

unread,
Nov 9, 2011, 1:06:23 PM11/9/11
to reddot-c...@googlegroups.com
We usually achieve this using something like this:

HTML Foundation Page:
<ul><%!! Navigation:OutputArea(NavName) !!%></ul>

Navigation Code:
<li><a href="<%!! Context:CurrentIndex.Page.GetUrl() !!%>"><%!! Context:CurrentIndex.Headline !!%></a>
<reddot:cms>

<if>
<query valuea="Context:CurrentIndex.HasChildren()" operator="==" valueb="Bool:True">
<htmltext><ul><nagivation:nextlevel></ul></htmltext>
</query>
<if>
</reddot:cms>
</li>

If you want the home page to be listed you would need to make a second Navigation Code content class and simply remove the reddot if statement and put the <navigation:nextlevel> after the closing <li> tag and set that to "special level: 1-1" and "selected only"

Joel Kinzel

unread,
Nov 9, 2011, 1:07:20 PM11/9/11
to reddot-c...@googlegroups.com
Note: The code I posted is for Navigation Manager based projects.

Andry Poernomo

unread,
Nov 10, 2011, 8:20:03 AM11/10/11
to reddot-c...@googlegroups.com
Hi Mark,

I'm using v. 10.

Andry

--

Andry Poernomo

unread,
Nov 10, 2011, 8:17:47 AM11/10/11
to reddot-c...@googlegroups.com

Hi Joel,

 

Thank you for the tips!

 

Using navigation manager works well! One more thing to perfect it, do you know how to make it to just display top 2 sub menus?

 

I want the landing pages to display top 2 sub menus, and if there are more than two, a MORE link will be displayed.

 

Eg.

 

Housing & living

- Accommodation

 

Careers

- Career Centre

- Field work education

- MORE

 

Cheers,

 

Andry

 

 

From: reddot-c...@googlegroups.com [mailto:reddot-c...@googlegroups.com] On Behalf Of Joel Kinzel
Sent: Thursday, 10 November 2011 2:06 AM
To: reddot-c...@googlegroups.com
Subject: Re: Questions on navigation

 

We usually achieve this using something like this:

--

You received this message because you are subscribed to the Google Groups "RedDot CMS Users" group.

To view this discussion on the web visit https://groups.google.com/d/msg/reddot-cms-users/-/4N5WUtZ25GAJ.

Ben Murphy

unread,
Nov 10, 2011, 6:46:17 PM11/10/11
to reddot-c...@googlegroups.com
Hi Andry,
 Your best bet is probably to use CurrentLevelCount to interrogate the position like so:

<!!% Context:CurrentLevelCount %!!>

This starts at 1 not 0. 

You can then test it via:

<if>
<query valuea="Context:CurrentLevelCount" operator=">=" valueb="Int:3">
<htmltext>
put your More html code here...
</htmltext>
</if>

Good luck :)
Ben.

Andry Poernomo

unread,
Nov 10, 2011, 7:09:46 PM11/10/11
to reddot-c...@googlegroups.com

Hi Ben,

 

Yes!! I figured that out last nite! Thank youuuu!! You’re a champ!

 

Andry

 

 

From: reddot-c...@googlegroups.com [mailto:reddot-c...@googlegroups.com] On Behalf Of Ben Murphy
Sent: Friday, 11 November 2011 7:46 AM
To: reddot-c...@googlegroups.com
Subject: Re: Questions on navigation

 

Hi Andry,

--

You received this message because you are subscribed to the Google Groups "RedDot CMS Users" group.

To view this discussion on the web visit https://groups.google.com/d/msg/reddot-cms-users/-/N_BTGOmwZmkJ.

Reply all
Reply to author
Forward
0 new messages