From 663d9422056de325f388f9775cf609bcd9764dd7 Mon Sep 17 00:00:00 2001 From: MarkBaker Date: Mon, 3 Aug 2015 19:40:16 +0100 Subject: [PATCH] Fix to HTML generation with charts that fall outside of the main data area, and fix to show trailing `/` in folders for the jpgraph in examples --- Classes/PHPExcel/Writer/HTML.php | 3 ++- Examples/36chartreadwriteHTML.php | 2 +- Examples/36chartreadwritePDF.php | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Classes/PHPExcel/Writer/HTML.php b/Classes/PHPExcel/Writer/HTML.php index fddf7b2..5c39ddc 100644 --- a/Classes/PHPExcel/Writer/HTML.php +++ b/Classes/PHPExcel/Writer/HTML.php @@ -577,9 +577,10 @@ class PHPExcel_Writer_HTML extends PHPExcel_Writer_Abstract implements PHPExcel_ } } } + $html = ''; $colMax++; - while ($row < $rowMax) { + while ($row <= $rowMax) { $html .= ''; for ($col = 'A'; $col != $colMax; ++$col) { $html .= ''; diff --git a/Examples/36chartreadwriteHTML.php b/Examples/36chartreadwriteHTML.php index 3ee8242..7fc26fd 100644 --- a/Examples/36chartreadwriteHTML.php +++ b/Examples/36chartreadwriteHTML.php @@ -46,7 +46,7 @@ include 'PHPExcel/IOFactory.php'; // Change these values to select the Rendering library that you wish to use // and its directory location on your server $rendererName = PHPExcel_Settings::CHART_RENDERER_JPGRAPH; -$rendererLibrary = 'jpgraph3.5.0b1/src'; +$rendererLibrary = 'jpgraph3.5.0b1/src/'; $rendererLibraryPath = '/php/libraries/Charts/' . $rendererLibrary; diff --git a/Examples/36chartreadwritePDF.php b/Examples/36chartreadwritePDF.php index 0a428a2..24d1c85 100644 --- a/Examples/36chartreadwritePDF.php +++ b/Examples/36chartreadwritePDF.php @@ -69,7 +69,7 @@ if (!PHPExcel_Settings::setPdfRenderer( // Change these values to select the Rendering library that you wish to use // for Chart images, and its directory location on your server $rendererName = PHPExcel_Settings::CHART_RENDERER_JPGRAPH; -$rendererLibrary = 'jpgraph3.5.0b1/src'; +$rendererLibrary = 'jpgraph3.5.0b1/src/'; $rendererLibraryPath = '/php/libraries/Charts/' . $rendererLibrary;