M
M
Mikhail Gilmutdinov2015-07-02 10:32:12
css
Mikhail Gilmutdinov, 2015-07-02 10:32:12

How to make cells (td) in one line (tr) under each other when changing the width of the browser?

Help me please!
Adapt the board.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
Z
zooks, 2015-07-02
@zooks

Usually done like this: one cell - one line.

table {
    width: 100%;
}
td {
    display: block;
    text-align: center;
    width: auto;
}

N
Nikita Borzenkov, 2015-07-02
@BashXP

Make not a table, but a pseudo-table with css from divs. Row - display:table-row; Cell - display:table-cell; When adapting a cell, set display:block; and that's it.

M
Mikhail Gilmutdinov, 2015-07-02
@Mixailhr

Thanks for answers! I ended up just rebuilding the table. In lines. But I will definitely try your options!

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question