highest level 'dummy' Menu item

Topics: General
Jan 23, 2014 at 5:50 PM
thanks for clarifying my little blackout!

I would like a specific 'Highest level' Menu item as a 'dummy' item I.e no ContentItem, link, etc. attached to it.
The 'dummy' item is just uesd to attach a Sub-Menu which carries the relevant 'contents'!

I tried to use the 'Link' version with leaving url blank - does not work!
I guess I could code it in the shape 'MenuItemLink-main-menu.cshtml' ... but I'm hoping for a simpler solution!?

what is the trick to do this
thanks for your time and advise, ed
Jan 24, 2014 at 12:24 PM
Try leaving the text blank, instead of URL. There is this pieve of code in MenuItem.cshtml: if (!HasText(Model.Text)) { @DisplayChildren(Model) } else ....
Jan 25, 2014 at 7:38 AM
thanks, well I was probably not quite clear:
Of course I would like to see the text - but suppress the href only!
``` <li class="dropdown">
<a href="/projets">Projets</a> 
If I leave - in the Menu item definition - the text blank; the Menu is not correct anymore!

any other ideas?
thanks for your time and hints, ed
Jan 26, 2014 at 8:12 PM
I'm not still sure if I understand the final mark-up want to achieve, but another idea (I haven't tried this): create a top level shape menu item, and put the submenues under it. Creatşng shape links is explained here: http://www.davidhayden.me/blog/shape-link-for-orchard-menus
In the shape template, you will probably need to use a @DisplayChildren(Model) call somewhere, to make it render the submenus. Good luck. On Sat, Jan 25, 2014 at 10:40 AM, edikaufmann <[email removed]> wrote:
Jan 28, 2014 at 7:37 AM
I'm obviously not very clear - so I try again:
  • All I want is a simple Menu with one sublevel.
  • Where the some TopLevel MenuItems do NOT carry a 'href' like "<a href="/projets">Projets</a>"
  • I only would like something like "<a>Projets</a> i.e. just the name NOTHING to link to!
  • the sublevel MenuItems of course will then call some 'ContentItems' using eg: "<a href="/projet-1">Projet 1</a>"
I'm pretty sure I miss here something simple - just do not see it!
PS: will of course checkout your given link!
thanks for time and hints, ed
Feb 1, 2014 at 6:53 PM
I have tested the Navigation -> Shape link option you suggested. It works - sort of!
I.e. I'm having an issue around the security / content Permission: how to hide a shape link menu item!?

well will do more testing ..
BUT, I still hope somebody comes up with a more elegant solution ( I still think/hope there is one!?)

thanks for your time, ed