Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- label {
- float: left;
- width: 100px;
- padding: 2px;
- }
- .c1 {
- float: left;
- width: 200px;
- }
- .c2 {
- float: left;
- width: 40px;
- margin-right: 10px;
- }
- .c3 {
- float: left;
- width: 150px;
- }
- .c1 input[type=text],
- .c2 input[type=text],
- .c3 input[type=text] {
- width: 100%;
- }
- .clear {
- clear: both;
- }
- .table {
- display: table;
- }
- .table .row {
- display: table-row;
- }
- .table .cell {
- display: table-cell;
- }
- .group {
- display: table;
- width: 100%;
- }
- .group .gcell {
- display: table-cell;
- }
- .table input {
- width: 100%;
- }
- <div class="table" style="width: 300px;">
- <div class="row">
- <div class="cell" style="width:40%;">
- <label for="name">Name</label>
- </div>
- <div class="cell">
- <input type="text" id="name" name="name" />
- </div>
- </div>
- <div class="row">
- <div class="cell">
- <label for="city">ZIP and city</label>
- </div>
- <div class="cell">
- <div class="group">
- <div class="gcell" style="width: 40%;">
- <input type="text" name="zip" style="width: 90%;" />
- </div>
- <div class="gcell">
- <input type="text" name="city" id="city" />
- </div>
- </div>
- </div>
- </div>
- </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement