PHPExcel文件导出出现找不到该文件,高手

WBOY
Release: 2016-06-13 13:32:33
Original
1535 people have browsed it

PHPExcel文件导出出现找不到该文件,求救高手!
环境:freeBSD服务器,PHP+MySQL
问题:做了一个excel导出功能,在windows本地与Linux测试环境都没有问题,在线上freeBSD出现找不到该文件。

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->
        $file_name = isset($_GET['exam_caption']) && !empty($_GET['exam_caption']) ?   $_GET['exam_caption'] : time().mt_rand(1000, 9999);
        $outputFileName = iconv ( 'UTF-8', 'gb2312', $file_name . '.xlsx' );
        header ( 'Pragma:public' );
        header ( 'Expires:0' );
        header ( 'Cache-Control:must-revalidate,post-check=0,pre-check=0' );
        header ( 'Content-Type:application/force-download' );
        header ( 'Content-Type:application/vnd.ms-excel' );
        header ( 'Content-Type:application/octet-stream' );
        header ( 'Content-Type:application/download' );
        header ( 'Content-Disposition:attachment;filename=' . $outputFileName );
        header ( 'Content-Transfer-Encoding:binary' );
        $objWriter->save ( 'php://output' );

Copy after login


求教高手!!!!

------解决方案--------------------
你把路劲打印出来看看呗!若相对路径不行就换绝对路径啊!
------解决方案--------------------
没有log,怎么调呀
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!