Um pequeno exemplo de como exportar em XLS (Excel) usando PHP.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
header('Content-Type: text/html; charset=utf-8'); | |
header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); | |
header ('Last-Modified: ' . gmdate("D,d M YH:i:s") . ' GMT'); | |
header ('Cache-Control: no-cache, must-revalidate'); | |
header ('Pragma: no-cache'); | |
header ('Content-type: application/x-msexcel'); | |
header ('Content-Disposition: attachment; filename="' . date('Y-m-d_H-i-s') . '.xls"'); | |
header ("Content-Description: PHP Generated Data" ); | |
?> | |
<table> | |
<tr> | |
<td>Crie seu conteúdo conforme o necessário</td> | |
</tr> | |
</table> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment