From 8eb4c6e20a6dc8110b53a5511f71c37341c5df55 Mon Sep 17 00:00:00 2001 From: Dany De Bontridder Date: Fri, 20 Apr 2018 21:36:39 +0200 Subject: [PATCH] New version of libreoffice use the numeric in another way --- include/class/acc_bilan.class.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/class/acc_bilan.class.php b/include/class/acc_bilan.class.php index 1dff742f0..8f17f63e5 100644 --- a/include/class/acc_bilan.class.php +++ b/include/class/acc_bilan.class.php @@ -454,9 +454,14 @@ class Acc_Bilan /* allow numeric cel in ODT for the formatting and formula */ if ( is_numeric($a) ) { + /* -- for libreOffice < 5 or openoffice -- */ $searched='office:value-type="string">'.$f2_str; $replaced='office:value-type="float" office:value="'.$a.'">'.$f2_str; $line_rtf=str_replace($searched, $replaced, $line_rtf); + /* -- for libreOffice > 5 -- */ + $searched='office:value-type="string" calcext:value-type="string">'.$f2_str; + $replaced='office:value-type="float" office:value="'.$a.'" calcext:value-type="float">'.$f2_str; + $line_rtf=str_replace($searched, $replaced, $line_rtf); }