0
有什麼簡單快捷的方法可以在html中內聯css嗎?這是我的樣本HTML我用我的代碼html中的內聯css
.table > thead > tr > th {
border: solid #000 1px;
padding: 5px;
font-size: 14px;
}
.table > tbody > tr > td {
border: solid #000 1px;
font-size: 14px;
}
.table > thead > tr > th {
background-color: #2882d7 ;
color: #fff;
font-family: verdana;
}
.table > tbody > tr > td {
background-color: #f5f5f5 ;
color: #000;
font-family: verdana;
padding: 15px;
}
<!DOCTYPE html>
<html lang="en">
<head>
<link href="style.css" rel="stylesheet">
</head>
<body>
<form>
<table class="table">
<thead>
<tr>
<th>Name</th>
<th>Email</th>
</tr>
</thead>
<tbody>
<tr>
<td>James</td>
<td>[email protected]</td>
</tr>
</tbody>
</table>
</form>
</body>
</html>
爲什麼要內聯CSS? – j08691
你的意思是你有很多外部樣式表引用,你想讓程序自動將它們轉換成'