Skip to content
This repository has been archived by the owner on Jan 2, 2019. It is now read-only.

Bug fix: c:max and c:min elements shall NOT be inside c:orientation elements #869

Merged
merged 1 commit into from
Mar 31, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Bug fix: c:max and c:min elements must not be inside c:orientation el…
…ements. They shall be inside c:scaling elements. Otherwise they are ignored by Excel and Libreoffice
  • Loading branch information
vitalyrepin committed Mar 23, 2016
commit 44918984a1b938c311699cd79918a01c1d4fa392
6 changes: 4 additions & 2 deletions Classes/PHPExcel/Writer/Excel2007/Chart.php
Original file line number Diff line number Diff line change
Expand Up @@ -540,8 +540,6 @@ private function writeValueAxis($objWriter, PHPExcel_Chart_PlotArea $plotArea, $
}

$objWriter->startElement('c:scaling');
$objWriter->startElement('c:orientation');
$objWriter->writeAttribute('val', $xAxis->getAxisOptionsProperty('orientation'));

if (!is_null($xAxis->getAxisOptionsProperty('maximum'))) {
$objWriter->startElement('c:max');
Expand All @@ -555,6 +553,10 @@ private function writeValueAxis($objWriter, PHPExcel_Chart_PlotArea $plotArea, $
$objWriter->endElement();
}

$objWriter->startElement('c:orientation');
$objWriter->writeAttribute('val', $xAxis->getAxisOptionsProperty('orientation'));


$objWriter->endElement();
$objWriter->endElement();

Expand Down