You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@lenya.apache.org by Chris Woods <cs...@gmail.com> on 2006/01/06 19:45:38 UTC

Section Labels in the Menu

Does any know how to make a menu with the following characteristics?

Initial menu:
Home <-- index page for the publication when clicked displays as follows

Section menus:
Home<-- index page is still displayed
|-Chapter 1<--No content here, when clicked it reveals sub pages
|-Chapter 2<--No content here, when clicked it reveals sub pages
|-Chapter 3<--No content here, when clicked it reveals sub pages

Subsection menus:
Home
-Chapter 1
  |-page1<--click for content
  |-page2<--click for content
-Chapter 2
-Chapter 3

Thanks very much.

Chris

Re: Section Labels in the Menu

Posted by so...@apache.org.
On 1/6/06, Chris Woods <cs...@gmail.com> wrote:
> Does any know how to make a menu with the following characteristics?
>  Initial menu:
>  Home <-- index page for the publication when clicked displays as follows
>
>  Section menus:
>  Home<-- index page is still displayed
>  |-Chapter 1<--No content here, when clicked it reveals sub pages
>  |-Chapter 2<--No content here, when clicked it reveals sub pages
>  |-Chapter 3<--No content here, when clicked it reveals sub pages
>
>  Subsection menus:
>  Home
>  -Chapter 1
>    |-page1<--click for content
>    |-page2<--click for content
>  -Chapter 2
>  -Chapter 3

You need documents for the top-level pages, so they show in the
Navigation.  Then decide how you want to hide them:

1. Create the top-level pages so they redirect to "page 1".  You could
handle this:
- Using HTML (META tag) or JS in your XSL.  Add a Navigation Element
that contains the URL of the first child.
- Use the XMAP: If the path is for the top-level and not the homepage,
then open the first child.  It would be easy if the first child always
has the same docID (such as "page1").  Otherwise you need something
that returns the docID of the first child.

2. Write dynamic code that opens the top-level menus without opening
the page.  You'll need a Navigation Element that always creates DIVs
for the top two levels in the menu.  Then add JS so the top-level
items change the DIV's visibility without refreshing the page.  Also
choose one:
- All the top-level pages say "Sorry, you should not have accessed this page."
- The XMAP redirect requests for a top-level page to a "Sorry" page.
- Something redirects requests for a top-level page to the first page as in #1.

3. Rewrite Lenya so "Menu-only" pages are possible.  (And please contribute it.)

solprovider

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org