CSS Adapter for the SiteMapPath control.
03 Dec 2006Wrote a CSS Adapter for the SiteMapPath control. I wanted a breadcrumb trail with clean link tags only. Renders a clean set of link tags within a div tag (and optionally a span tag).
Usage:
Add the SiteMapPathAdapter.cs file to your web project. (rename the .txt file to .cs)
Add a .browser file to the web site. Add the following entry in the controlAdapters element.
<adapter controlType ="System.Web.UI.WebControls.SiteMapPath" adapterType ="SiteMapPathAdapter" />
Drag and drop the control on to the web form
«/span>asp:SiteMapPath ID=”SiteMapPath1” runat=”server” CssSelectorId=”breadcrumbs” >
«/span>/asp:SiteMapPath>
Use the CssSelectorId attribute to give the surrounding div an identifier.
More on CSS Adapters
CSS Control Adapter Toolkit for ASP.NET 2.0