0
I want to upload an HTML table and leave it at the same time as the form to the left of it, I have tried it in several ways (top, vertical-align, etc), but without result.
body {
background: #d6d6f5;
padding-left: 4%;
}
.caixa {
width: 40%;
background: #ffffff;
display: inline-block;
border: 20px solid #d6d6f5;
border-radius: 1px;
vertical-align: left;
}
.divtabela {
text-align: center;
display: inline-block;
}
.tabela {
background: #ffffff;
width: 200%;
margin-left: 80px;
}
<!DOCTYPE html>
<html lang="pt-br">
<head>
<title>Cadastro de clientes</title>
<meta charset="UTF-8">
<link rel="stylesheet" href="css/style.css">
<link REL="SHORTCUT ICON" HREF= "imgs/icone.png" type="image/x-icon">
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.css">
</head>
<input type="button" class="voltar" value="←" onclick=" return BackToComMenu()">
<body>
<div class="caixa">
<center><img id="logo" src="imgs/logo.png" alt="Logo da FullTime"></center>
<main>
<form action="php/cadastrar.php" method="POST" id="FormCadastro">
<p>Cadastro de Clientes</p>
<div class="inputWithIcon">
<input name="nome" type="text" placeholder="Nome">
<i class="fa fa-user fa-lg fa-fw" aria-hidden="true" name="user"></i>
</div>
<div class="inputWithIcon">
<input name="email" type="text" placeholder="Email" onclick="return checarEmail()" >
<i class="fa fa-envelope fa-lg fa-fw" aria-hidden="true" name="user"></i>
</div>
<div class="inputWithIcon">
<input name="telefone" type="text" placeholder="Telefone" maxlength="11">
<i class="fa fa-phone fa-lg fa-fw" aria-hidden="true" name="user"></i>
</div>
<div class="inputWithIcon">
<input name="cpf" type="text" placeholder="CPF" maxlength="14" OnKeyPress="formatar('###.###.###-##', this)">
<i class="fa fa-address-card fa-lg fa-fw" aria-hidden="true" name="user"></i>
</div>
<input type="submit" value="Cadastrar" name="enviar" onclick="return cadastrar()">
</div>
<div class="divtabela">
<table class="tabela">
<thead>
<tr>
<th >Email <i class="fa fa-envelope fa-lg fa-fw"></i></th>
<th >CPF <i class="fa fa-credit-card fa-lg fa-fw"></i></th>
</tr>
</thead>
<tbody>
<tr>
<td>Teste1</td>
<td>000.000.000-00</td>
</tr>
<tr>
<td>Teste2</td>
<td>999.999.999-99</td>
</tr>
</tbody>
</table>
</div>
</form>
</main>
</body>
Do you want to leave the table of the same size as the form or move up the table and let it line up? the title of your question and the description say different things.
– user181348
I want to align the table up so it’s the same time as the form.
– Jonatan