Come posso creare una funzione in js che mi gestisca la seguente cosa:
supponendo di avere codice html scritto cosi:
<table width="100%" >
<tr>
<td>1</td>
<td width="100%"><input type="text" name="1" value="{1}"></td>
</tr>
<tr>
<td>2</td>
<td width="100%"><input type="text" name="2" value="{1}"></td>
</tr>
<tr>
<td>3</td>
<td width="100%"><input type="text" name="3" value="{1}"></td>
</tr>
<tr>
<td>4</td>
<td width="100%"><input type="text" name="4" value="{1}"></td>
</tr>
eccc
</table>
Questo codice mi viene generato da un progemma..e nonposso modificarlo, come faccio se
volessimanipolare il layout a io piacimento con js?..
Io vorrei spostare e ottere questo..
<table width="100%" >
<tr>
<td>1</td>
<td width="100%"><input type="text" name="1" value="{1}"></td>
<td>2</td>
<td width="100%"><input type="text" name="2" value="{1}"></td>
</tr>
<tr>
<td>3</td>
<td width="100%"><input type="text" name="3" value="{1}"></td>
<td>4</td>
<td width="100%"><input type="text" name="4" value="{1}"></td>
</tr>
eccc
</table>
inmaniera automatica...
come faccio?
AIUTOOOOOOOOOO