html maintain text in one line

Solutions on MaxInterview for html maintain text in one line by the best coders in the world

showing results for - "html maintain text in one line"
Stefania
15 Jan 2020
1#parent {
2    list-style: none;
3    width: 100%;
4    height: 90px;
5    margin: 0;
6    padding: 0;
7    white-space: nowrap;
8    overflow-x: auto;
9    overflow-y: hidden;
10}
11
12#parent > li {
13    display: inline-block;
14    width: 50%;
15    height: 100%;
16    background-color: red;
17}
18
19#parent > li:nth-child(even) {
20    background-color: blue;
21}
Ariana
26 Jun 2016
1<ul id="parent">
2    <li>Box #1</li>
3    <li>Box #2</li>
4    <li>Box #3</li>
5</ul>