For a simple site that only has the user browsing through pages in one section, you don’t need the [*lang*] TV or the [[SetLang]] snippet at all.
For the three top-level menu items, you need to edit those three documents, and in the TopMenuStart TV (under the section for editing the content) you need to replace the default value with the ID of their parent, for the three under the English folder that will be the ID of the English folder, for the three under the German folder that will be the ID of the German folder. Now each of those six top-level pages will show the correct top menu, as will all of their children. For example, say the English folder is 1 and the German folder is 20. For the three folder/documents under the English folder, change the TV to "1". For the three folder/documents under the German folder, change the TV to 20. Now everybody should be showing the correct menu items for the top menu, the default on start, and whichever one the user chose if he wants to change languages.
Quote from: sottwell at May 11, 2006, 11:40 PM
For a simple site that only has the user browsing through pages in one section, you don’t need the [*lang*] TV or the [[SetLang]] snippet at all.........
You suggestion of a demo is a good one; I’ll try to take some time and make one up!

English (only content is the FirstChildRedirect snippet)
---- Home
---- Fields
---- doc 1
---- doc 2
---- News
---- article 1
---- article 2
---- Support
---- doc 1
---- doc 2
German (only content is the FirstChildRedirect snippet)
---- Home
---- Fields
---- doc 1
---- doc 2
---- News
---- article 1
---- article 2
---- Support
----doc 1
---- doc 2
How you handle it from here depends on what you do on your site. If you have no login, you don’t need the cookie. You use DropMenu with a startDoc of 0 and levelLimit of 1 for the language menu.
Your site start document (set in the system configuration in Manger) will be the Home page of whichever language you want to be the default.
Clicking on "English" will take you to the English home page. The top menu will have DropMenu with a startDoc of whatever your English folder id is. Use a TV for that, with @INHERIT as the default value, and set the value in the TV only in the English folder/document.
The same for the German folder. Set its StartDoc TV to its ID. Leave all the other document’s StartDoc TV as the default; this way they will inherit the value you set in the top level folder. So your top menu DropMenu will look like this:
Code:
[!DropMenu?startDoc=`[*StartDoc*]` &levelLimit=`1`!]
The left menu will use either [*id*] or [*parent*] as the startDoc value, depending on which page you are on. Use a TV to contain the snippet call, and have the default value look like this:
Code:
<div id="leftmenu"> [!DropMenu?startDoc=`[*parent*]`&levelLimit=`1`!] </div>
This way, you only need to change the value [*parent*] to [*id*] for the three top-level pages. The second level pages will already be using the correct value!
The TV would be [*parent*] by default (when you actually create the TV). In the TV for the three main folder/documents/ change that to [*id*]. Just leave it as [*parent*] for the submenu items. By setting [*parent*] as the default value when you create the TV, you don’t have to edit the submenu documents; they will already have the value they need.
If your submenus go deeper than a single level, you would be better off putting @INHERIT as the default when you create the TV, then in the parent folder/documents change it to that document’s ID (the actual number, not [*id*]!). Now all of its children will inherit that value.
That’s done in the CSS, I would recommend articles from A List Apart on taming lists, and a Google search will find a lot of different ways to do that.
http://www.google.com/search?hl=en&q=css+horizontal+menu&btnG=Google+Search
