Re: SiteMapPath control doesn't like named anchors in sitemap

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Just as a follow-up, I have a work around that at least gets the SiteMapPath
working, though it can't be sued on the sub-menu.

Because the page the named anchors target is the same, I am able to cut the
node entries down in the full sitemap to just the page without the #name
suffix (again, no duplicates). This permits the breadcrumb to correctly
interpret where it is in relation to the sitemap and the page being viewed.

I guess I can live without the side menu selected page being highlighted,
given the breadcrumb now operates.

Would still appreciate any responses on how the use of named anchors might
be made to be recognised though!

Al



"Alec MacLean" <alec.maclean@xxxxxxxxxxxxxxxxxxx> wrote in message
news:eqgQMts8GHA.4552@xxxxxxxxxxxxxxxxxxxxxxx
Hi.

I'm using VS2005 Pro to work on a website project for my company.

The site has several navigation elements, all based on the standard VS2005
navigation components.

I have high-level section navigation provided via a horizontal menu, a
SiteMapPath to provide a breadcrumb and a vertical menu component on the
left edge.

The SiteMapPath uses a sitemap that covers the full site. The top menu
uses a smaller sitemap file to specify section headings. The side menus
are changeable via the use of a set of separate sitemap files, as our
website is broken up into sub-project folders using the WAP add-in and
nested master pages. Each section gets its own sub-sitemap.

The combination allows for the side (sub) menu to change depending on
where in the site the visitor is in the site. This system works great -
until I was asked to provide a menu that displays several links that
target the same page.

As you'll know if you'e used sitemap files, they do not allow two entries
that point to the same address. My solution to this has been to add named
anchor tags to the target pages and then add the "#anchorname" combination
to the url in the sitemap file.

This then correctly parses and allows for the menu to work as desired by
my project stakeholder, but it has the negative impact of not being
interpreted by the SiteMapPath (breadcrumb) control, which behaves as if
the node was not entered at all and blanks the control completely.

It also prevents the Selected page style of the side menu operating, so
other than the actual page content, I lose any navigational indicator to
present the current location to the user.

Has anyone come across this problem and found, or know of, a solution?

Thanks.

Al



.



Relevant Pages

  • Re: Site navigation & Role manager
    ... in web.config you have to redefine the SiteMapProvider to be security sensitive ... and will only show navigation links to pages the current user is authorized. ... now connect the menu/treeview control to a sitemap datasource. ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Select parent nodes in sitemap when any of its children are selected
    ... I'm in the process of building some navigation for a website. ... controls that consume the sitemap. ... When a child page is selected the parent node on the navigation bar ... If I had a parent navigation bar category called Books, ...
    (microsoft.public.dotnet.framework.aspnet)
  • Teil-Dynamische Sitemap
    ... Zur Zeit hat die Website auf der MasterPage eine statische Sitemap. ... Diese beinhaltet eine horizontale Navigation oben und eine vertikale Navigation links. ... Durch klicken auf + Kunden sollen nun die ersten 10 Kunden angezeigt werden, darunter ein Eintrag mehr Kunden..., falls mehr als 10 Kunden vorhanden ...
    (microsoft.public.de.german.entwickler.dotnet.asp)
  • Re: Produce a site map from a Web.Sitemap
    ... If you page through the article, it shows how the navigation can work ... from a master page. ... I want to create a sitemap (lets call it a map to avoid confusion with .NET ... I dont want to use a treeview control as it looks too much ...
    (microsoft.public.dotnet.framework.aspnet)
  • RE: newbie: menu / sitemap problem
    ... into a separate sitemap file and creating a new SitemapProvider that the ... And a sidebar menu to the left. ... When the "Network" menuitem in my main menu is clicked the sidebar menu ...
    (microsoft.public.dotnet.framework.aspnet)