lo que pasa es que todo esta dentro de un div:
Código PHP:
<td colspan='3'>
<div id='divResultado' name='divResultado' align='center'>
<?
if($pr_mon=='S')
{
echo"<table width='100%'>
<tr><th class='combo0'>Cod</th><th class='combo0'>Tipo/Sub-tipo</th><th class='combo0'>Producto</th><th class='combo0'>Descripcion</th><th class='combo0'>Cant.</th><th class='combo0'>Prec(S/.)</th><th class='combo0'>Subtotal</th>
</tr>";
$total=0;
for($i=0;$i<count($_SESSION['usuario']['carrito']);$i++)
{
foreach ($_SESSION['usuario']['carrito'][$i] as $k => $v)
{
if($k=='codigo')
echo"<tr><td class='texto8'>$v</td>";
if($k=='tiposubtipo')
echo"<td class='texto8'>$v</td>";
if($k=='nombre')
echo"<td class='texto8'>$v</td>";
if($k=='descripcion')
echo"<td class='texto8'>$v</td>";
if($k=='cantidad')
echo"<td class='texto8'><input type='text' name='cant$i' value='$v' class='form1' size='15' onkeypress=\"javascript:var key=window.event.keyCode;if (key==13) document.form11.precio$i.focus();\"></input></td>";
if($k=='precio')
echo"<td class='texto8'><input type='text' name='precio$i' class='form1' value='".number_format($v, 2, '.', ' ')."' class='form' size='15' onkeypress=\"javascript:var key=window.event.keyCode;document.form11.subtotal$i.focus();\" ></input></td>";
if($k=='subtotal')
{
$total+=$v;
echo"<td class='texto8'><input type='text' name='subtotal$i' class='form1' value='".number_format($v, 2, '.', ' ')."' class='form' size='15'></input></td>
<td><a href='javascript:;' onclick=\"enviaQuery('divResultado','myajax.php?opcion=borrar_itempr&i=$i&tipo=fac');document.form11.regal.focus()\"><img src='images/trash.gif' border='0'></a></td></tr>";}
}
}
echo"<tr><td colspan='7' align='right' class='bordenaranja'><b>Total SIGV: S/.".number_format($total/1.19, 2, '.', ' ')."</b> <b>IGV: S/.".number_format($total-($total/1.19), 2, '.', ' ')."</b> <b>Total: S/.".number_format($total, 2, '.', ' ')."</b></td></tr></table>";
}
else
{
echo "<table width='100%'>
<tr><th class='combo0'>Cod</th><th class='combo0'>Tipo/Sub-tipo</th><th class='combo0'>Producto</th><th class='combo0'>Descripcion</th><th class='combo0'>Cant.</th><th class='combo0'>Prec(S/.)</th><th class='combo0'>Prec(US$.)</th><th class='combo0'>Subtotal(S/.)</th><th class='combo0'>Subtotal(US$.)</th>
</tr>";
$total=0;
$totald=0;
for($i=0;$i<count($_SESSION['usuario']['carrito']);$i++)
{
foreach ($_SESSION['usuario']['carrito'][$i] as $k => $v)
{
if($k=='codigo')
echo"<tr><td class='texto8'>$v</td>";
if($k=='tiposubtipo')
echo"<td class='texto8'>$v</td>";
if($k=='nombre')
echo"<td class='texto8'>$v</td>";
if($k=='descripcion')
echo"<td class='texto8'>$v</td>";
if($k=='cantidad')
echo"<td class='texto8'><input type='text' name='cant$i' value='$v' class='form1' size='15' onkeypress=\"javascript:var key=window.event.keyCode;if (key==13) document.form11.precio$i.focus();\"></input></td>";
if($k=='precio')
echo"<td class='texto8'><input type='text' name='precio$i' class='form1' value='".number_format($v, 2, '.', ' ')."' class='form' size='15' onkeypress=\"javascript:var key=window.event.keyCode;if (key==13) document.form11.preciod$i.focus();\"></input></td>";
if($k=='preciod')
echo"<td class='texto8'><input type='text' name='preciod$i' class='form1' value='".number_format($v, 2, '.', ' ')."' class='form' size='15' onkeypress=\"javascript:var key=window.event.keyCode;if (key==13) document.form11.subtotal$i.focus();\"></input></td>";
if($k=='subtotal')
{
$total+=$v;
echo"<td class='texto8'><input type='text' name='subtotal$i' class='form1' value='".number_format($v, 2, '.', ' ')."' class='form' size='15'></input></td>";}
if($k=='subtotald')
{
$totald+=$v;
echo"<td class='texto8'><input type='text' name='subtotald$i' class='form1' value='".number_format($v, 2, '.', ' ')."' class='form' size='15'></input></td>
<td><a href='javascript:;' onclick=\"enviaQuery('divResultado','myajax.php?opcion=borrar_itempr&i=$i&tipo=fac&tc='+document.form11.tc.value);document.form11.regal.focus()\"><img src='images/trash.gif' border='0'></a></td></tr>";}
}
}
echo"<tr><td colspan='9' align='right' class='bordenaranja'><b>Total SIGV: S/.".number_format($total/1.19, 2, '.', ' ')."</b> <b>IGV: S/.".number_format($total-($total/1.19), 2, '.', ' ')."</b> <b>Total: S/.".number_format($total, 2, '.', ' ')."</b></td></tr>
<tr><td colspan='9' align='right' class='bordenaranja'><b>Total SIGV: US$. ".number_format($totald/1.19, 2, '.', ' ')."</b> <b>IGV: US$. ".number_format($totald-($totald/1.19), 2, '.', ' ')."</b> <b>Total: US$.".number_format($totald, 2, '.', ' ')."</b></td></tr></table>";
}?>
</div>
</td>
y se supone que al borrar me hace el enfoque; el otro elemento esta dentro del form pero mas abajo:
Código PHP:
<td>
<b>Regalos:</b> </td>
<td>
<input type='text' name='regal' class='form' value='123' onfocus="enviaQuery('divmuestra','myajax.php?opcion=verdolares');"></input></td>
<td>