我試圖設置是一個表中的對象的一些風格,但問題是,屬性不會被應用到實際的對象。CSS表格屬性
的.tblData工作正常,但在標籤和文本框的屬性都應該是或表,但CSS犯規中出現任何ASP.net標籤或文本框獲得適用於他們。
.tblData {
border: solid;
border-width: 1px;
height: 200px;
color: rgb(45,40,128);
background-color: white;
width: 100%;
border-radius:3px;
margin-top:3px;
}
/*Class for the labels*/
.tblData label {
width: 13%;
color:black;
border-radius:3px;
font-family:verdana;
border-radius:3px;
border-color:rgba(45,40,128,0.75);
border-width:1px;
}
/*Class for the data textboxes*/
.tblData textbox {
border-color: rgba(45,40,128,0.75);
border-width: 1px;
background-color:rgba(45,40,128,0.10);
font-family:Verdana;
border-radius:3px;
}
這是HTML(不能顯示所有的它,因爲該表是巨大的):
<table id="tblAddress" class="tblData">
<tr>
<td class="auto-style3">
<asp:Label ID="lblACNO" runat="server" Text="ACNO" CssClass="Datalabelcolumn"></asp:Label></td>
<td class="auto-style2">
<asp:TextBox ID="txtACNO" runat="server" CssClass="autosuggest" Width="20%" ToolTip="This is a test tooltip"></asp:TextBox>
</td>
顯示你的HTML標記太.... CSS只有不會幫助...或者可能的jsfiddle是最好的選擇! – NoobEditor
@NoobEditor我從表中加入了一些HTML作爲一個例子。 – connersz
測試盒呈現在輸入類型和標籤跨度呈現根據它 –