mirror of
https://github.com/PHPOffice/PhpSpreadsheet.git
synced 2026-09-15 04:26:25 +00:00
Merge pull request #3487 from PHPOffice/TextGrid-Helper_Use-pre-rather-than-code
Fix issue with online samples - Use <pre> tag in Helper Grid
This commit is contained in:
@@ -48,7 +48,7 @@ class TextGrid
|
||||
|
||||
public function render(): string
|
||||
{
|
||||
$this->gridDisplay = $this->isCli ? '' : '<code>';
|
||||
$this->gridDisplay = $this->isCli ? '' : '<pre>';
|
||||
|
||||
$maxRow = max($this->rows);
|
||||
$maxRowLength = strlen((string) $maxRow) + 1;
|
||||
@@ -58,7 +58,7 @@ class TextGrid
|
||||
$this->renderRows($maxRowLength, $columnWidths);
|
||||
$this->renderFooter($maxRowLength, $columnWidths);
|
||||
|
||||
$this->gridDisplay .= $this->isCli ? '' : '</code>';
|
||||
$this->gridDisplay .= $this->isCli ? '' : '</pre>';
|
||||
|
||||
return $this->gridDisplay;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user