Reputation: 15538
I have a page structured like this
<div id = "part1" >
<div id = "cat1" >
<asp:Label cssClass="titles" runat="Server" />
<-- more code ... -->
</div>
<div id = "cat2" >
<asp:Label cssClass="titles" runat="Server" />
<-- more code ... -->
</div>
<div id = "cat3" >
<asp:Label cssClass="titles" runat="Server" />
<-- more code ... -->
</ div>
<div id = part2" >
<-- some code ... -->
</div>
<div id = part3" >
<-- some code ... -->
</div>
The corresponding CSS file is like this:
#cat1 , #cat2 , #cat3
{
float:left;
width:auto;
padding:5px;
border-width:3px;
border-style:solid;
border-color:#800000;
}
.titles
{
padding:5px;
border-width:3px;
border-style:solid;
border-color: #800000 ;
}
My goal is to have 3 columns with colored border and for each column one title (asp.net labels) with colored border.
But all I get is three columns and no borders. Moreover titles seems to don't stay in the "part1 div" (I don't know how to explain better,it's like paddings impact).
What am I doing wrong?
Thank you
Upvotes: 0
Views: 1890
Reputation: 4912
I don't seem to be getting the first problem - which broswers are you trying it on?
one problem seems to be you're setting cssClass="titles" instead of class="titles"
am guessing the "</ div>" is a misstype of "</div>" & that you also want to close #part1 before opening #part2 (?)
is it definitely loading the css file? could you try embedding it in the html to check?
Upvotes: 1