(v2.0) Menu Control

bri189a

Senior Contributor
Joined
Sep 11, 2003
Messages
1,004
Location
VA
The following on my master page results in blue text, not white. Is this a bug?

<td style="height: 24px">
<div style="position: absolute; top: 77px; left: 158px;">
<asp:Menu ID="SiteMenu" runat="server" Orientation="Horizontal" DataSourceID="SiteMapDataSource" Width="180px">
<StaticMenuItemStyle ForeColor="White" />
</asp:Menu>
<asp:SiteMapDataSource ID="SiteMapDataSource" runat="server" ShowStartingNode="False" />
</div>
</td>

It's weird, it generates the following mark-up for the anchor element:

<a class="ctl00_SiteMenu_1 ctl00_SiteMenu_3" href="/VSDOTNET/Project1/Page1.aspx">Page1</a>

How is this a valid CSS class for one (notice the space in the class name)? And two this definitely doesn't say 'style="color: White;"'
 
I found that if I don't use a SiteMapDataSource then I don't get the error. I can continue using the SiteMapDataSource if I put

.ctl00_SiteMenu_1
{
.color: White !important;
}

in my style sheet.
 
Back
Top