Buenos dias!
mi problema es que genero el archivo Excel pero en ves de aparecer los datos en cada columna y fila, aparecen todos en una sola fila..
Aca les paso el string que tiene todos las variables generadas por PHP
Código PHP:
Ver original$excel.=$banSuc."\t".$nroruc."\t".$fecha."\t".$datos[0]."\t".$datos[1]."\t".$datos[2]."\t".$datos[3]."\t".$datos[4]."\t".$datos[5]."\t".$datos[6]."\t".$datos[7]."\t".$datos[8]."\t".$datos[9]."\t".$datos[10]."\t".$datos[11]."\t".$datos[12]."\t".$datos[13]."\t".$datos[14]."\t".$datos[15]."\t".$datos[16]."\t".$cot."\n";
?>
Código HTML:
Ver original<form action="Generador.php" method ="POST"> <input type="hidden" name="export" value="<?php echo $excel;?>"/>
<input type="submit" value="Descargar Excel">
Aca pasa esa variable por formulario a Generador.php
Que su codigo es el siguiente.
Código PHP:
Ver original<?
$excel=$_POST['export'];
header('Content-type: application/vnd.ms-excel'); header("Content-Disposition: attachment; filename=Lista.xls");
<h1>Lista CIC</h1>
<table border="2" cellspacing="0" cellpadding="0">
<tr>
<th>Nro Banco-Suc</th>
<th>Nro Cuenta</th>
<th>Fecha de Liquidacion</th>
<th>Saldo Actual $</th>
<th>Saldo Actual U$S</th>
<th>Suma Consumos Pend. de liquidar en $</th>
<th>Suma Consumos Pend. de liquidar en U$S</th>
<th>Suma otros Conceptos Pend. de liquidar en $</th>
<th>Suma otros Conceptos Pend. de liquidar en U$S</th>
<th>Suma Cuotas Consumos Pend. de liquidar en $</th>
<th>Suma Cuotas Consumos Pend. de liquidar en U$S</th>
<th>Suma Cuotas Prest. pend. de liquidar en $</th>
<th>Suma Ajuste positivo en $</th>
<th>Suma Ajuste negativo en $</th>
<th>Suma Ajuste positivo en U$S</th>
<th>Suma Ajuste negativo en U$S</th>
<th>Suma de pagos pendientes en $</th>
<th>Suma de pagos pendientes en U$S</th>
<th>Deuda Total $</th>
<th>Deuda Total U$S</th>
<th>Cotizacion</th>
</tr>
<tr>
<td>
<?php print $excel; ?>
</td>
</tr>
</table>
Espero que puedan ayudarme!! se lo agradeceria mucho!