create table through div

Solutions on MaxInterview for create table through div by the best coders in the world

showing results for - "create table through div"
Emmanuelle
11 Jan 2019
1<div class="Table">
2    <div class="Title">
3        <p>This is a Table</p>
4    </div>
5    <div class="Heading">
6        <div class="Cell">
7            <p>Heading 1</p>
8        </div>
9        <div class="Cell">
10            <p>Heading 2</p>
11        </div>
12        <div class="Cell">
13            <p>Heading 3</p>
14        </div>
15    </div>
16    <div class="Row">
17        <div class="Cell">
18            <p>Row 1 Column 1</p>
19        </div>
20        <div class="Cell">
21            <p>Row 1 Column 2</p>
22        </div>
23        <div class="Cell">
24            <p>Row 1 Column 3</p>
25        </div>
26    </div>
27    <div class="Row">
28        <div class="Cell">
29            <p>Row 2 Column 1</p>
30        </div>
31        <div class="Cell">
32            <p>Row 2 Column 2</p>
33        </div>
34        <div class="Cell">
35            <p>Row 2 Column 3</p>
36        </div>
37    </div>
38</div>
Valery
25 Jan 2017
1<style type="text/css">
2    .Table
3    {
4        display: table;
5    }
6    .Title
7    {
8        display: table-caption;
9        text-align: center;
10        font-weight: bold;
11        font-size: larger;
12    }
13    .Heading
14    {
15        display: table-row;
16        font-weight: bold;
17        text-align: center;
18    }
19    .Row
20    {
21        display: table-row;
22    }
23    .Cell
24    {
25        display: table-cell;
26        border: solid;
27        border-width: thin;
28        padding-left: 5px;
29        padding-right: 5px;
30    }
31</style>