4 error_reporting(E_ALL);
5 ini_set(
'display_errors', TRUE);
6 ini_set(
'display_startup_errors', TRUE);
7 date_default_timezone_set(
'Europe/London');
9 define(
'EOL',(PHP_SAPI ==
'cli') ?
PHP_EOL :
'<br />');
11 date_default_timezone_set(
'Europe/London');
40 require_once dirname(__FILE__) .
'/../Classes/PHPExcel.php';
47 array(
'', 2010, 2011, 2012),
48 array(
'Q1', 12, 15, 21),
49 array(
'Q2', 56, 73, 86),
50 array(
'Q3', 52, 61, 69),
51 array(
'Q4', 30, 32, 0),
122 $chart->setTopLeftPosition(
'A7');
123 $chart->setBottomRightPosition(
'H20');
130 echo
date(
'H:i:s') ,
" Write to Excel2007 format" ,
EOL;
133 $objWriter->save(str_replace(
'.php',
'.xlsx', __FILE__));
134 echo
date(
'H:i:s') ,
" File written to " , str_replace(
'.php',
'.xlsx', pathinfo(__FILE__, PATHINFO_BASENAME)) ,
EOL;
138 echo
date(
'H:i:s') ,
" Peak memory usage: " , (memory_get_peak_usage(
true) / 1024 / 1024) ,
" MB" , EOL;
141 echo
date(
'H:i:s') ,
" Done writing file" ,
EOL;
142 echo
'File has been created in ' , getcwd() ,
EOL;
static createWriter(PHPExcel $phpExcel, $writerType='')
Create PHPExcel_Writer_IWriter.
if($is_dev) echo "Review changes write something in WHATSNEW and and then commit with log PHP_EOL
date( 'd-M-Y', $objPHPExcel->getProperties() ->getCreated())
const GROUPING_PERCENT_STACKED
Create styles array
The data for the language used.