JSFiddle - React, Tailwind, and code Playground
by Juan Muñoz
HTML
<div id="formulario">
<table id="id1">
<tbody><tr style="background-color: white;"><td>
<table border="0" align="center" style="margin-left: 150px;">
<tbody><tr><td colspan="3">
<table style="font-size: 8px;background-color: #CEF6EC;" border="1">
<tbody><tr>
<th colspan="2">ROL UNICO TRIBUTARIO</th>
</tr>
<tr>
<td id="num">03</td>
<td><input id="emp" type="text" readonly="false" value=""></td>
</tr>
</tbody></table>
</td>
<td>
<table border="1" style="height: 33px;background-color: #CEF6EC;">
<tbody><tr>
<td rowspan="2" id="num">15</td>
<td align="center"><b>Mes</b></td>
<td align="center" width="4%"><b>Año</b></td>
</tr>
<tr>
<td align="center"><select id="mes" style="font-weight: bolder;font-size: 10px" onchange="cargaForm29();">
<option value="">Seleccione mes</option>
<option...
JavaScript
$(document).ready(function (){
var arreglo = "";
var empresa="";var periodo="";
$('input').each(function (){
var valor_id = parseInt($(this).attr('id'));
if ( valor_id > 0 ){
arreglo = arreglo +","+ valor_id;
//console.log("Valor ID"+valor_id+"\n");
}
});
console.log(arreglo);
})