Page 1 of 1

exporting html to MSword dynamically

Posted: Fri Apr 24, 2009 7:05 pm
by sychurn
Hi everyone,

I got this problem. I need to export a page to word dynamically. I mean whatever data there in my forms, that would be the data that will be exported to a word file. I have this code but I dont know how to make this dyamic.

Code: Select all

 
<?php
$vExcelFileName="export". ".doc";
header("Content-type: application/x-ms-download"); //#-- build header to download the excel file
header("Content-Disposition: attachment; filename=$vExcelFileName");
header('Cache-Control: public');
echo "hai";
?>