好我試過了表設計。我的問題顯示在下圖中。把<hr>放在裏面<tr>
我只是想設置border
或hr
在.total_amt_tr
類。
我試過了裏的.chkout_hr
類的hr標籤,但它不起作用。邊框頂部正在努力到.bordr_hr
類。
我的問題是:
1.Is它使用
hr
內tr
標籤不錯的辦法。如果(不好)
{
如何設置邊境像圖像?
}
2.Border長度在左右兩端應該有一些空的空格。像邊界長度是90%,它應該居中。
.ordr_table_two{
width: 100%;
}
.amount_blue{
font-size: 17px;
color: #2795CA;
font-weight: 500;
text-transform: capitalize;
}
.amount_blue .icon_rupee i{
color: #2795CA;
}
.ordr_table_two thead tr th{
text-transform: capitalize;
padding: 13px 0px 13px 0px;
font-weight: 600;
font-size: 15px;
}
.ordr_table_two tbody tr td{
text-transform: capitalize;
font-weight: 300;
font-size: 14px;
padding: 2px 0px 2px 0px;
}
.ordr_table_two tbody tr td p{
text-transform: uppercase;
}
.chkout_hr{
width: 95%;
margin-left: auto;
margin-right: auto;
display: table;
margin-top: 10px;
margin-bottom: 10px;
color: #E2E2E2;
}
.total_amt{
color: #2795CA;
font-size: 17px;
font-weight: 400;
}
.total_amt_blue{
color: #2795CA;
}
.total_amt_blue i{
margin-right: 4px;
}
.total_amt_tr{
height: 50px;
}
.total_amt_tr .total_amt_txt{
font-size: 15px;
font-weight: 600;
text-transform: capitalize;
padding-left: 5%;
}
<table class="ordr_table_two">
<thead>
<tr>
<th>ticket no:</th>
<th>attendee name:</th>
<th>attendee type:</th>
<th>activity date:</th>
<th>amount:</th>
</tr>
</thead>
<tbody>
<tr>
<td><p>tnpge_206</p></td>
<td>prabagaran</td>
<td>member</td>
<td>jan 03,2016 - 11:15 AM</td>
<td><p class="amount_blue"><span class="icon_rupee"><i class="fa fa-inr" aria-hidden="true"></i></span>1000.00</p></td>
</tr>
<tr>
<td><p>tnpge_207</p></td>
<td>rajkumar</td>
<td>non-member</td>
<td>jan 03,2016 - 11:15 AM</td>
<td><p class="amount_blue"><span class="icon_rupee"><i class="fa fa-inr" aria-hidden="true"></i></span>1000.00</p></td>
</tr>
<tr>
<td><p>tnpge_209</p></td>
<td>dinesh kumar</td>
<td>PG Trainee</td>
<td>jan 03,2016 - 11:15 AM</td>
<td><p class="amount_blue"><span class="icon_rupee"><i class="fa fa-inr" aria-hidden="true"></i></span>1000.00</p> </td>
</tr>
<tr class="bordr_hr"><hr class="chkout_hr">
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr class="total_amt_tr">
<td></td>
<td></td>
<td></td>
<td class="total_amt_txt">total amount:</td>
<td><p class="total_amt"><span class="total_amt_blue"><i class="fa fa-inr" aria-hidden="true"></i></span>4000.00</p></td>
</tr>
</tbody>
</table>
沒有,'hr'不是tr'的'有效孩子。 'tr'唯一有效的孩子是'th'和'td' [whatwg:4.9.8 tr元素](https://html.spec.whatwg.org/multipage/tables.html#the-tr-element ) –
不,它是無效的HTML(https://developer.mozilla。org/en/docs/Web/HTML/Element/tr)你可以添加一個'