Wrox Programmer Forums
|
ASP.NET 4.5.1 General Discussion For ASP.NET 4.5.1 discussions not relating to a specific Wrox book
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 4.5.1 General Discussion section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 9th, 2016, 10:29 PM
Authorized User
 
Join Date: Nov 2014
Posts: 91
Thanks: 2
Thanked 1 Time in 1 Post
Default SiteMapPath Does Not Display

I am developing my first website and opened it in Goggle Chrome. It did not display the SiteMapPath.

Here is the code from Web.sitemap.
Code:
<?xml version="1.0" encoding="utf-8" ?>
<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >
  <siteMapNode url="~/" title="Home" description="Home" >
    <siteMapNode url="~/Default.aspx" title="Home"  description="Go to the homepage" />
    <siteMapNode url="~/Units/Default.aspx" title="Units"  description="Pictures of Premise" >
      <siteMapNode url="~/Units/RiverFront.aspx" title="RiverFront" description="Down by the river" />
    </siteMapNode>
    <siteMapNode url="~/Fishing/Default.aspx" title="Fishing" description="Sockeye Capital of the World" >
      <siteMapNode url="~/Fishing/Freshwater.aspx" title="Freshwater" description="Silvers and Pinks" />
      <siteMapNode url="~/Fishing/Saltwater.aspx" title="Saltwater"  description="Halibut, Rock Fish, and Ling Cod" />
    </siteMapNode>
]    <siteMapNode url="~/About/Default.aspx" title="About" description="About this Site" >
      <siteMapNode url="~/About/Contact.aspx" title="Contact Us" description="Contact Us" />
      <siteMapNode url="~/About/AboutU.aspx" title="About Us" description="About Us" />
    </siteMapNode>
  </siteMapNode>
</siteMap>
Here is part of the master page code for the navigation code and the SiteMapPath Control.
Code:
<nav>
        <asp:Menu ID="Menu1" runat="server" CssClass="MainMenu" DataSourceID="SiteMapDataSource1" Orientation="Horizontal"
          StaticEnableDefaultPopOutImage="False" BackColor="Black" ForeColor="White" Width="824px">
        </asp:Menu>
        <asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" ShowStartingNode="False" />
      </nav>
      <section id="MainContent">
        <asp:SiteMapPath ID="SiteMapPath1" runat="server"></asp:SiteMapPath><br />
        <asp:ContentPlaceHolder ID="cpMainContent" runat="server">
        </asp:ContentPlaceHolder>
      </section>
Here is the HTML page source code for the SiteMapPath control.
Code:
 <section id="MainContent">
        <span id="SiteMapPath1"><a href="#SiteMapPath1_SkipLink" style="position:absolute;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden;">Skip Navigation Links</a><a id="SiteMapPath1_SkipLink"></a></span><br />
I do not know why the SiteMapPath is not displayed.





Similar Threads
Thread Thread Starter Forum Replies Last Post
SiteMapPath control and themes txkimmers BOOK: Beginning ASP.NET 4 : in C# and VB 2 May 4th, 2012 11:47 AM
Why do we not associate SiteMapPath Control with any datasource pennkaiser BOOK: Beginning ASP.NET 4 : in C# and VB 3 August 6th, 2010 02:27 AM
How to create SiteMapPath in PHP? firblazer PHP How-To 0 July 14th, 2008 09:33 PM
with pages in a subdir sitemappath and treeview d thenoseknows ASP.NET 2.0 Basics 1 June 15th, 2006 11:10 AM
SiteMapPath Control Question lcsgeek BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 6 February 7th, 2006 06:18 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.