[Zope3-Users] Zope 3 and menus

Stephan Richter srichter at cosmos.phy.tufts.edu
Sun Nov 11 23:19:50 EST 2007


On Tuesday 13 March 2007, eXt wrote:
>         I've got a problem with menus. I'd like to define a global menu,
> and then add some options to it depending on actual context (view
> registered for specific interface). The problem is that when I define
> global menu element link like: action="/index.html" it generates url which
> omits my folder structure which shold be: root/my_site/index.html  and
> creates: root/index.html.

That's correct. You asked for index.html at the root level.

> On the other side when i use: action="index.html" 
> the url which is created is always relative.

That behavior is also correct.

> I'd like to be able to define 
> my_site (which is in fact a Site object) to be root for actions.

Well, you cannot really do this. This is one of the many limitations of the 
browser menu implementation. If you want truly flexible menus, consider 
implementing them using viewlets. It will not be as declarative, but gives 
you much more flexibility.

Regards,
Stephan
-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training


More information about the Zope3-users mailing list