Developer forum

Forum » Templates » Accessing the new Navigation Tag

Accessing the new Navigation Tag

Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply
Hi there,

Is there a way to access the new Navigation Tag you can set on a page (on the Layout dialog) from a NavigationProvider? I need to mark some pages as special and the Navigation Tag seems like a great candidate. However, it doesn't appear to be a member of the PageNavigationItem class. Right now, I abuse MouseOver but that doesn't feel right....

Imar

Replies

 
Vladimir
Reply
Hi Imar!
Did you try this approach:  
            http://developer.dynamicweb-cms.com/Forum.aspx?PID=48&ThreadID=23903

Vladimir

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply
Hi Vladimir,

Yeah, that would work, but feels extremely inefficient. I don't want to query the entire page table for *each* request. And certainly not when I already get the complete page structure passed to my ProcessTree method ;-)

Adding the NavigationTag to the PageNavigationItem class would solve the problem, as it will then automatically get populated when the tree structure is built....

Imar
 
Nicolai Høeg Pedersen
Reply
This post has been marked as an answer
Hi Imar

Just added the NavigationTag attribute to the page tree. The attribute is only there if it has a value.

Out with Service release sometime next week. TFS6505

Votes for this answer: 0
 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Is it then available in the XML for the menu? Or on the PageNavigationItem class in code as well? This

The attribute is only there if it has a value.
 
seems to imply XML....

Imar
 
Nicolai Høeg Pedersen
Reply
Both.
 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Great. If this is going to work the way I think it is, you just fulfilled an enhancement request I made about 3 years ago ;-)

TFS2546....

Imar
 

 
Nicolai Høeg Pedersen
Reply
Fast , inexpensive and ready to use... :-)
 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Hahaha, yes. Well, better late than never. And I've seen loads of other new features since then that did get implemented really fast. I think no-one considered this request to be important.... ;-)

Imar

 

You must be logged in to post in the forum