5ini_set(
'display_errors', TRUE);
6ini_set(
'display_startup_errors', TRUE);
7date_default_timezone_set(
'Europe/London');
9define(
'EOL',(PHP_SAPI ==
'cli') ?
PHP_EOL :
'<br />');
11date_default_timezone_set(
'Europe/London');
40require_once dirname(__FILE__) .
'/../Classes/PHPExcel.php';
47 array(
'Counts',
'Max',
'Min',
'Min Threshold',
'Max Threshold' ),
48 array(10, 10, 5, 0, 50 ),
49 array(30, 20, 10, 0, 50 ),
50 array(20, 30, 15, 0, 50 ),
51 array(40, 10, 0, 0, 50 ),
52 array(100, 40, 5, 0, 50 ),
127$chart->setTopLeftPosition(
'A7');
128$chart->setBottomRightPosition(
'H20');
135echo
date(
'H:i:s') ,
" Write to Excel2007 format" ,
EOL;
143echo
date(
'H:i:s') ,
" File written to " , str_replace(
'.php',
'.xlsx', pathinfo(__FILE__, PATHINFO_BASENAME)) ,
EOL;
150echo
date(
'H:i:s') ,
" Done writing file" ,
EOL;
151echo
'File has been created in ' , getcwd() ,
EOL;
date( 'd-M-Y', $objPHPExcel->getProperties() ->getCreated())
memory_get_peak_usage(true)/1024/1024)
An exception for terminatinating execution or to throw for unit testing.
static createWriter(PHPExcel $phpExcel, $writerType='')
Create PHPExcel_Writer_IWriter.