Clear, accurate, high quality discussion

Forum

 
ForumForumDiscussions and...Discussions and....Net framework ....Net framework ...Can I avoid duplication by getting the page title from the sitemap?Can I avoid duplication by getting the page title from the sitemap?
Previous Previous
 
Next Next
New Post
 04/04/2008 22:00
 

In a web application the page's title is likely shown in the browser's title bar and may be displayed on the page.  When using an XMLSiteMap the text is also in the sitemap.  This code will get the title from the site map entry belonging to the current page.

if (SiteMap.CurrentNode != null)
            pageTitle  = SiteMap.CurrentNode.Title;


Cheers,
- Richard
If this post helped you over a problem, or taught you something new, please login and rate it. Ratings are in the drop down in the top left corner
Previous Previous
 
Next Next
ForumForumDiscussions and...Discussions and....Net framework ....Net framework ...Can I avoid duplication by getting the page title from the sitemap?Can I avoid duplication by getting the page title from the sitemap?

Forum Usage Guidelines

The forums are a place for all to exchange ideas and techniques, and to post and answer questions.  All are welcome to read, registration is required to post. 

If you learn somthing new, discover or acquire a new technique, then please take a moment to register and rate the post that just helped you.  This site does not send spam and it does not release your personal details.  Full details in the site privacy policy.

We have some simple posting guidelines to keep the forums a pleasant and informative environment.

  • No flames, no trolls
  • No profanity, no racism
  • Site management has the final word on approving or removing any thread, post, or comment
  • English language only please