I want to export my web page in excel file. below code -
<?php
$file="My_Excel.xls";
header("Content-type: application/vnd.ms_excel");
header("Content-Disposition: attachment; filename=$file");
?>
Not working please suggest.
Right Code is -
<?php
$file="My_Excel.xls";
header("Content-type: application/vnd.ms-excel");
header("Content-Disposition: attachment; filename=$file");
?>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.