私はこのテーブルを作成する必要がありますが、colspanとrowspanは私の脳を狂ってしまいます。助けてください。このhtmlテーブルの作成方法は?
実験用のブランクJsfiddle、 - http://jsfiddle.net/3pbuT/2/
私はこのテーブルを作成する必要がありますが、colspanとrowspanは私の脳を狂ってしまいます。助けてください。このhtmlテーブルの作成方法は?
実験用のブランクJsfiddle、 - http://jsfiddle.net/3pbuT/2/
かなりまっすぐ.....あなたの混乱は、あなたが持っていた行の数です。そのテーブルには2行しかありません。
<table>
<tr>
<td rowspan="2"></td>
<td rowspan="2"></td>
<td colspan="4"></td>
<td rowspan="2"></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
これを試してみてください...あなたは、Dreamweaverのツールを持っている場合、あなたは非常に簡単にこれを行うことができます....
<table width="200" border="1">
<tr>
<td rowspan="2"> </td>
<td rowspan="2"> </td>
<td colspan="4"> </td>
<td rowspan="2"> </td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
<html>
<head>
<style type='text/css'>
table {
border-spacing:0;
}
td {
border:1px solid grey;
}
</style>
</head>
<body>
<table>
<tr>
<td rowspan='2'>1 col, 2 rows</td>
<td rowspan='2'>1 col, 2 rows</td>
<td colspan='4'>4 col, 1 row</td>
<td rowspan='2'>1 col, 2 rows</td>
</tr>
<tr>
<td>1 col, 1 row</td>
<td>1 col, 1 row</td>
<td>1 col, 1 row</td>
<td>1 col, 1 row</td>
</tr>
</table>
</body>
</html>
編集 - 私はagaiをお勧めしたいあなた自身でそれをやる方法を学ぶことはないので、WYSIWYGの編集者は何もありません。学習はいくつかの頭痛、確かに、しかしあなたは知っている。男に魚を与える...
最も簡単な方法は、Dreamweaverのですが、それはCOLSPANとROWSPANに対処するために多くを取らない、私は非常に少しの思考でこれをやった、と私はちょうどそれが正しかったことを確認するjsfiddle使用しました。
お楽しみください。
<table>
<tr>
<td rowspan="2"></td>
<td rowspan="2"></td>
<td colspan="4"></td>
<td rowspan="2"></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
<table>
<thead>
<tr>
<th rowspan="2">город 1</th>
<th rowspan="2">город 2</th>
<th colspan="4">город 3</th>
<th rowspan="2">город 4</th>
</tr>
<tr>
<th>город 5</th>
<th>город 6</th>
<th>город 7</th>
<th>город 8</th>
</tr>
</thead>
</table>
このような何か:あなたが行くここ
<table>
<tr>
<td rowspan="2"> </td>
<td rowspan="2"> </td>
<td colspan="4"> </td>
<td rowspan="2"> </td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
<html>
<head>
</head>
<body>
<table border="1">
<tr>
<td rowspan="2">one</td>
<td rowspan="2">Two</td>
<td colspan="4">Im big!</td>
<td rowspan="2">Last</td>
</tr>
<tr>
<td rowspan="2">one</td>
<td rowspan="2">Two</td>
<td>Part 1</td>
<td>Part 2</td>
</tr>
</table>
</body>
</html>
..
<table border="1">
<tr>
<td rowspan="2"></td>
<td rowspan="2"></td>
<td colspan="4"></td>
<td rowspan="2"></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
コlspanは列を結合し、rowspanは行を結合します。したがって、最大で行がいくつあるか、そこに最大でいくつの列があるかを調べます。そして、あなたが列/行結合
<table border="1">
<tr>
<td>a</td>
<td>b</td>
<td>c</td>
<td>d</td>
<td>e</td>
<td>f</td>
<td>g</td>
</tr>
<tr>
<td>h</td>
<td>i</td>
<td>j</td>
<td>k</td>
<td>l</td>
<td>m</td>
<td>n</td>
</tr>
</table>
:あなたのケースでは
あなたは最大で7列、最大で2行があるすべてのための
<table border="1" style="padding:5px;border-spacing:10px">
<tr>
<td rowspan="2">a (former a)</td>
<td rowspan="2">b (former b)</td>
<td colspan="4">c (former c)</td>
<td rowspan="2">d (former g)</td>
</tr>
<tr>
<td>e</td>
<td>f</td>
<td>g</td>
<td>h</td>
</tr>
</table>
Absolutellyのおかげで、あなたは私のお尻保存しました^ _^ – NiLL
あなたはhttp://www.w3schools.com/html/または(ドイツ語を読むことができる場合)http://de.selfhtml.org/ –
のようないくつかの基本的なウェブサイトを見てみたいかもしれません。リンクのために。 – NiLL