Setting the page's title and sitemap node to the same text

Mar 21, 2011 at 4:53 PM
Edited Mar 21, 2011 at 5:08 PM


I'm using ASP.NET MVC 3.  I would like to set the view's title and the sitemap node to the same text.  How would I do this?  Where would it be done and are there any samples?

So if I have the following link /Product/Create then I would like the page title to be "Capture New Product".  And the sitemap trail must look like Home > Product > Capture New Product

How would one write tests for this in NUnit? Are tests necessary?


Mar 25, 2011 at 10:14 PM

In the view, set the Title to the SiteMap.CurrentNode.Title