Javascript 导出Excel表格
你好 如何在excel中导出此表。 我已经在几个网站上搜索过了,但仍然没有成功,有人可以帮助我,这里我留下了我正在使用的代码并生成了表Javascript 导出Excel表格,javascript,php,html,excel,Javascript,Php,Html,Excel,你好 如何在excel中导出此表。 我已经在几个网站上搜索过了,但仍然没有成功,有人可以帮助我,这里我留下了我正在使用的代码并生成了表 <table id="tbAplicaciones" align="center"> <thead> <tr > <th width="10%" scope="col">id_solicita</th> <th
<table id="tbAplicaciones" align="center">
<thead>
<tr >
<th width="10%" scope="col">id_solicita</th>
<th width="10%" scope="col">Nombre</th>
<th width="10%" scope="col">Destino</th>
<th width="10%" scope="col">Folio</th>
<th width="10%" scope="col">Fecha Pago</th>
<th width="10%" scope="col">Cantidad Solicitada</th>
<th width="10%" scope="col">Tipo de Gasto</th>
<th width="10%" scope="col">Importe de Gasto</th>
</tr>
</thead>
<tfoot>
<?php
$id=0;
while ($clientes = pg_fetch_object($Cat))
{
if ($numfila == 0){ $class = "alt"; $numfila = 1; } else { $class = ""; $numfila = 0; }
echo "<tr class'".$class."' style=\"height: 5px;\">";
echo "<td align='center'>".$clientes->id_solicita."</td>";
echo "<td>".utf8_decode($clientes->nombre)."</td>";
echo "<td align='center'>".$clientes->destino."</td>";
echo "<td align='center'>".$clientes->folio_gasto."</td>";
echo "<td align='center'>".$clientes->fechapago."</td>";
echo "<td align='center'>".$clientes->importe."</td>";
echo "<td align='center'>".$clientes->tipogasto."</td>";
echo "<td align='center'>".$clientes->importegasto."</td>";
echo "</tr>";
$id=$id+1;
}
if( $id == 0 )
// echo "Sin Sollicitudes Para Mostrar";
echo $usr2;
pg_close();
?>
</tfoot>
<tfoot>
</table>
</div> </body> </html> <?php
function ceros($numero, $ceros=2)
{
return sprintf("%0".$ceros."s", $numero );
}?>
<script type="text/javascript" src="jquery-1.3.2.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="src/jquery.table2excel.js"></script>
请求身份证
名义
德斯蒂诺
对开本
费查帕戈
康蒂达德酒店
提波德加斯托
加斯托进口酒店
我建议您查看PHPExcel库()
问候,,
埃德