Php cash Upload Excle file

Source: Internet
Author: User
Tags php excel
Php uploads Excle FILES. to upload excel files in php, only excel files are displayed when you select FILES, and how to determine $ upfile =$ _ FILES ["upfile"]; $ type & nbsp; = & nbsp; $ upfile ["type"]; & nbsp; $ type is an exce php file for uploading Excle files
To upload an EXCEL file in php, only the EXCEL file is displayed when you select a file, and how to determine $ upfile =$ _ FILES ["upfile"]; $ type = $ upfile ["type"]; $ type is excel. I tried $ type = "xls". what should it be like, another problem is that during the upload, not all files are first uploaded to a temporary file and then moved to the specified target. how can I delete this temporary file from PHP Excel and share it:
------ Solution --------------------
1. $ upfile ["type"]:

Xla application/vnd. ms-excel
Xlc application/vnd. ms-excel
Xll application/x-excel
Xlm application/vnd. ms-excel
Xls application/vnd. ms-excel
Xlt application/vnd. ms-excel
Xlw application/vnd. ms-excel

2. you do not need to worry about the temporary directory. after the upload program is executed, the system will automatically delete the temporary files.
------ Solution --------------------
Determine the extension.

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.