How to not generate. to download the DOC file, extract the database content and download it. do not generate the DOC file on the server, you only need to generate a file in the cache when you click it and download the generated file. I have already done so, but I do not know how to directly click download without generating the file, after the HEADER is configured, how can I not generate the HEADER. provides the download of DOC files.
Now we need to use this function to extract the database content and download it to the. DOC file.
But do not generate files on the server. you can only generate and download files directly in the cache when clicking.
Now, I have generated and downloaded the file.
Just click to download without generating a file.
------ Solution --------------------
After HEADER configuration, directly use echo $ content
$ Content is the content you need. you can organize it first and click it to create it. this is the same as reading a file, but you do not need to generate a file.
------ Solution --------------------
[Code = php]
Header ("Content-type: application/msword ");
Echo "the variables in the document content are stored here ";
[/Code]
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.