From 43b760501a9d78e8cb818e079b5679054ad746f0 Mon Sep 17 00:00:00 2001 From: Mark Baker Date: Mon, 28 Oct 2019 20:37:12 +0100 Subject: [PATCH] Text data locale for fixedformat (#1220) * Apply Locale settings to result of FIXEDFORMAT method call --- src/PhpSpreadsheet/Calculation/TextData.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/PhpSpreadsheet/Calculation/TextData.php b/src/PhpSpreadsheet/Calculation/TextData.php index 050c1a9b..ea00ef1c 100644 --- a/src/PhpSpreadsheet/Calculation/TextData.php +++ b/src/PhpSpreadsheet/Calculation/TextData.php @@ -273,7 +273,12 @@ class TextData $decimals = 0; } if (!$no_commas) { - $valueResult = number_format($valueResult, $decimals); + $valueResult = number_format( + $valueResult, + $decimals, + StringHelper::getDecimalSeparator(), + StringHelper::getThousandsSeparator() + ); } return (string) $valueResult;