baozi
baozi

Reputation: 709

ASP.net sitemap fails to navigate?

I am new to Asp.net and I had some trouble with menu navigation. I had the Web.sitemap

<siteMapNode url="~/" title="Home" description="Home">

<siteMapNode url="~/Default" title="Home" description="Go to the homepage" />

<siteMapNode url="~/Reviews/Default" title="Reviews" description="Reviews published on this site">
  <siteMapNode url="~/Reviews/AllByGenre" title="By Genre" description="All Reviews Grouped by Genre" />
  <siteMapNode url="~/Reviews/All" title="All Reviews" description="All Reviews" />
</siteMapNode>

<siteMapNode url="~/About/Default" title="About" description="About this Site">
  <siteMapNode url="~/About/Contact" title="Contact Us" description="Contact Us" />
  <siteMapNode url="~/About/AboutUs" title="About Us" description="About Us" />
</siteMapNode>

<siteMapNode url="~/Login" title="Login" description="Log in to this web site" />

and the start page Default.aspx gives enter image description here

But it just gives HTTP Error 404.0 not found errorwhen I try to navigate. URL is http://localhost:24186/About/AboutUs

enter image description here

Upvotes: 0

Views: 48

Answers (1)

Nuru Salihu
Nuru Salihu

Reputation: 4948

url ="~/About/Default" . Try add the .aspx like

url="~/About/Default.aspx"

I am not sure though. Cant see issue otherwise. I normally add the .aspx and i think it should be there.

Upvotes: 1

Related Questions