IIS Not Working with IOFactory and .xlsx

Topics: Developer Forum
Apr 23, 2012 at 11:21 AM
Edited Apr 23, 2012 at 11:22 AM

Hi All

This code works perfectly under apache but under IIS the output CSV file is simply filled with random symbols. Does anyone have any ideas why?

require_once '/PHPExcel/PHPExcel/IOFactory.php';
$excel = PHPExcel_IOFactory::load($xlsx_import_file);
$writer = PHPExcel_IOFactory::createWriter($excel, 'CSV');
$writer->save($csv_output_file);

$xlsx_import_file is the source path and $csv_output_file is the destination path

Thanks in advance!