Alterar TH
Innerhtml
by Rapha Souza
HTML
<script src="//code.jquery.com/jquery-3.3.1.slim.min.js"></script>
<link rel="stylesheet" href="//stackpath.bootstrapcdn.com/bootstrap/4.1.0/css/bootstrap.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js"></script>
<script src="//stackpath.bootstrapcdn.com/bootstrap/4.1.0/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<!DOCTYPE html>
<html>
<body>
<h2>JavaScript Loops</h2>
<button onclick="atualizaNomesTH();">
Teste
</button>
<input type="text" id="nomeParente2" value="Joao">
<input type="text" id="nomeParente3" value="Carlos">
<input type="text" id="nomeParente4" value="Raphael">
<div class="table-responsive">
<table class="table table-bordered">
<thead>
<tr>
<th>Comprovantes</th>
<th> Candidato</th>
<th id="th2">2</th>
<th id="th3">3</th>
<th id="th4">4</th>
<th id="th5">5</th>
<th id="th6">6</th>
<th id="th7">7</th>
<th id="th8">8</th>
<th id="th9">9</th>
<th id="th10">10</th>
</tr>
</thead>
<tbody>
<tr>
<td> Residência da Mãe</td>
<td><button type="button" onclick="showCamera('');" class="btn btn-default btn-xs">Anexar</button></td>
<td><button type="button" onclick="showCamera('');" class="btn btn-default btn-xs">Anexar</button></td>
<td><button type="button" onclick="showCamera('');" class="btn btn-default btn-xs">Anexar</button></td>
<td><button type="button" onclick="showCamera('');" class="btn btn-default btn-xs">Anexar</button></td>
<td><button type="button" onclick="showCamera('');" class="btn btn-default btn-xs">Anexar</button></td>
<td><button...
CSS
.row {
background: #f8f9fa;
margin-top: 20px;
}
.col {
border: solid 1px #6c757d;
padding: 10px;
}