Error reported in PHPExcel

Source: Internet
Author: User
There is a project that needs to introduce the PHPExcel class library to generate the excel table document. When writing the test sample, there is no problem. But when I introduce my project, all the errors will be reported in the PHPExcel library. I just wrote dephpexcel. {code...} after the PHP File ...} "-& amp; gt; & quot; always prompts syntaxerrorunexp...

A project needs to introduce the PHPExcel class library to generate an excel table document.
There is no problem when writing the test sample.
However, when I introduce my project, all errors will be reported for the entire PHPExcel library,

After I include the PHPExcel. php file

// Set propertiesecho date('H:i:s') . " Set properties\n";$objPHPExcel->getProperties()->setCreator("Maarten Balliauw");$objPHPExcel->getProperties()->setLastModifiedBy("Maarten Balliauw");$objPHPExcel->getProperties()->setTitle("Office 2007 XLSX Test Document");$objPHPExcel->getProperties()->setSubject("Office 2007 XLSX Test Document");$objPHPExcel->getProperties()->setDescription("Test document for Office 2007 XLSX, generated using PHP classes.");

"->" Always prompts syntax error unexpected '->'

What is the situation and how to solve it?

Reply content:

A project needs to introduce the PHPExcel class library to generate an excel table document.
There is no problem when writing the test sample.
However, when I introduce my project, all errors will be reported for the entire PHPExcel library,

After I include the PHPExcel. php file

// Set propertiesecho date('H:i:s') . " Set properties\n";$objPHPExcel->getProperties()->setCreator("Maarten Balliauw");$objPHPExcel->getProperties()->setLastModifiedBy("Maarten Balliauw");$objPHPExcel->getProperties()->setTitle("Office 2007 XLSX Test Document");$objPHPExcel->getProperties()->setSubject("Office 2007 XLSX Test Document");$objPHPExcel->getProperties()->setDescription("Test document for Office 2007 XLSX, generated using PHP classes.");

"->" Always prompts syntax error unexpected '->'

What is the situation and how to solve it?

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.