Vertical CSS Menu in ASP.NET
-
Hi All, I'm creating a web application in ASP.NET and c#. What I'm trying to do is create a vertical menu similar to the blue one in this link: http://www.alistapart.com/articles/taminglists/ I've created these menus in the past but in just a plain HTML page not ASP.NET. When I try to apply the same format to the unorder list the look isn't the same so I was trying to create it using LinkButtons like so:
<span class="subMenuDiv">
<asp:LinkButton ID="link1" runat="server" CssClass="subMenu" Text="Case Info"></asp:LinkButton>
<asp:LinkButton ID="link2" runat="server" CssClass="subMenu" Text="Reportable Info"></asp:LinkButton>
</span>The CSS looks like this:
.subMenuDiv {
float: right;
width: 120px;
padding: 0 0 0 0;
border: none;
margin: 0;}.subMenu {
width: 100%;
margin: 0;
padding: 4px 10px 4px 10px;
text-decoration: none;
background-color: #CCCC99;
border: solid 1px black;
color: #666633;
text-align: left;}The problem I'm having is the border of the subMenu is showing up twice, i'm not sure why but I know the padding is linked to it. How do I get it so the border only shows on the outer edge of the linkButtons (subMenu items) and so only one border is shown? Any help would be great. Thanks
-
Hi All, I'm creating a web application in ASP.NET and c#. What I'm trying to do is create a vertical menu similar to the blue one in this link: http://www.alistapart.com/articles/taminglists/ I've created these menus in the past but in just a plain HTML page not ASP.NET. When I try to apply the same format to the unorder list the look isn't the same so I was trying to create it using LinkButtons like so:
<span class="subMenuDiv">
<asp:LinkButton ID="link1" runat="server" CssClass="subMenu" Text="Case Info"></asp:LinkButton>
<asp:LinkButton ID="link2" runat="server" CssClass="subMenu" Text="Reportable Info"></asp:LinkButton>
</span>The CSS looks like this:
.subMenuDiv {
float: right;
width: 120px;
padding: 0 0 0 0;
border: none;
margin: 0;}.subMenu {
width: 100%;
margin: 0;
padding: 4px 10px 4px 10px;
text-decoration: none;
background-color: #CCCC99;
border: solid 1px black;
color: #666633;
text-align: left;}The problem I'm having is the border of the subMenu is showing up twice, i'm not sure why but I know the padding is linked to it. How do I get it so the border only shows on the outer edge of the linkButtons (subMenu items) and so only one border is shown? Any help would be great. Thanks
Do not repost the same question to multiple forums. You have asked this yesterday in the .net framework forum.
I know the language. I've read a book. - _Madmatt
-
Do not repost the same question to multiple forums. You have asked this yesterday in the .net framework forum.
I know the language. I've read a book. - _Madmatt
-
Sorry for the report, I forgot about the ASP.NET message board and posted in the .NET instead. I'd like to remove it from the .NET message board if possible. Thanks
http://www.codeproject.com/Messages/1278599/How-to-get-an-answer-to-your-question.aspx[^] 6. Do not remove or empty a message if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.
I know the language. I've read a book. - _Madmatt
-
http://www.codeproject.com/Messages/1278599/How-to-get-an-answer-to-your-question.aspx[^] 6. Do not remove or empty a message if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.
I know the language. I've read a book. - _Madmatt