How do I set the width of columns in an Excel spreadsheet generated as HTML?

Posted on

Coding Problem :

I need to convert an HTML table and generate the file in excel.
How to set the width of columns in excel?
I create the HTML file using PHP and export using:

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="{$arquivo}"""" )
Answer :


Answer 1 :


Answer 2 :


Answer 3 :


Answer 4 :


Answer 5 :


Answer 6 :


Answer 7 :


Answer 8 :


Answer 9 :

Leave a Reply

Your email address will not be published.