diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php
index 3483635c944..1a4aa60a012 100644
--- a/htdocs/core/lib/functions.lib.php
+++ b/htdocs/core/lib/functions.lib.php
@@ -3419,10 +3419,10 @@ function dol_textishtml($msg,$option=0)
function dol_concatdesc($text1,$text2,$forxml=false)
{
$ret='';
- $ret.= (! dol_textishtml($text1) && dol_textishtml($text2))?dol_nl2br($text1, 0, $forxml):$text1;
- $ret.= (! empty($text1) && ! empty($text2)) ? ((dol_textishtml($text1) || dol_textishtml($text2))?($forxml?"
\n":"
\n") : "\n") : "";
+ $ret.= (! dol_textishtml($text1) && dol_textishtml($text2))?dol_nl2br($text1, 0, $forxml):$text1;
+ $ret.= (! empty($text1) && ! empty($text2)) ? ((dol_textishtml($text1) || dol_textishtml($text2))?($forxml?"
\n":"
\n") : "\n") : "";
$ret.= (dol_textishtml($text1) && ! dol_textishtml($text2))?dol_nl2br($text2, 0, $forxml):$text2;
- return $ret;
+ return $ret;
}
/**
diff --git a/htdocs/core/modules/commande/doc/pdf_einstein.modules.php b/htdocs/core/modules/commande/doc/pdf_einstein.modules.php
index a39c4a5a4a6..082339490a2 100644
--- a/htdocs/core/modules/commande/doc/pdf_einstein.modules.php
+++ b/htdocs/core/modules/commande/doc/pdf_einstein.modules.php
@@ -261,9 +261,9 @@ class pdf_einstein extends ModelePDFCommandes
for ($i = 0 ; $i < $nblignes ; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
diff --git a/htdocs/core/modules/expedition/doc/pdf_expedition_rouget.modules.php b/htdocs/core/modules/expedition/doc/pdf_expedition_rouget.modules.php
index 4a28d6d257c..01888689100 100644
--- a/htdocs/core/modules/expedition/doc/pdf_expedition_rouget.modules.php
+++ b/htdocs/core/modules/expedition/doc/pdf_expedition_rouget.modules.php
@@ -226,9 +226,9 @@ class pdf_expedition_rouget extends ModelePdfExpedition
for ($i = 0; $i < $num; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
diff --git a/htdocs/core/modules/facture/doc/pdf_crabe.modules.php b/htdocs/core/modules/facture/doc/pdf_crabe.modules.php
index bbb503b7aa2..08ef7ae767c 100755
--- a/htdocs/core/modules/facture/doc/pdf_crabe.modules.php
+++ b/htdocs/core/modules/facture/doc/pdf_crabe.modules.php
@@ -264,7 +264,7 @@ class pdf_crabe extends ModelePDFFactures
for ($i = 0; $i < $nblignes; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
$pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
diff --git a/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php b/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php
index d5d05aac1c3..fd3f1242bf3 100644
--- a/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php
+++ b/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php
@@ -177,7 +177,7 @@ class pdf_soleil extends ModelePDFFicheinter
$this->_pagehead($pdf, $object, 1, $outputlangs, $hookmanager);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->MultiCell(0, 3, ''); // Set interline to 3
- $pdf->SetTextColor(0,0,0);
+ $pdf->SetTextColor(0,0,0);
$tab_top = 90;
$tab_top_newpage = (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)?42:10);
@@ -245,9 +245,9 @@ class pdf_soleil extends ModelePDFFicheinter
if ($valide > 0 || $object->specimen)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
@@ -257,7 +257,7 @@ class pdf_soleil extends ModelePDFFicheinter
$pdf->writeHTMLCell(0, 0, $curX, $curY, dol_concatdesc($txt,$desc), 0, 1, 0);
- $nexY = $pdf->GetY();
+ $nexY = $pdf->GetY();
$pageposafter=$pdf->getPage();
$pdf->setPage($pageposbefore);
$pdf->setTopMargin($this->marge_haute);
@@ -394,8 +394,8 @@ class pdf_soleil extends ModelePDFFicheinter
$pdf->SetXY(20,230);
$pdf->MultiCell(66,5, $outputlangs->transnoentities("NameAndSignatureOfInternalContact"),0,'L',0);
- $pdf->SetXY(20,235);
- $pdf->MultiCell(80,25, '', 1);
+ $pdf->SetXY(20,235);
+ $pdf->MultiCell(80,25, '', 1);
$pdf->SetXY(110,230);
$pdf->MultiCell(80,5, $outputlangs->transnoentities("NameAndSignatureOfExternalContact"),0,'L',0);
diff --git a/htdocs/core/modules/livraison/pdf/pdf_sirocco.modules.php b/htdocs/core/modules/livraison/pdf/pdf_sirocco.modules.php
index ca1d1a937d1..81d13e8cee5 100644
--- a/htdocs/core/modules/livraison/pdf/pdf_sirocco.modules.php
+++ b/htdocs/core/modules/livraison/pdf/pdf_sirocco.modules.php
@@ -183,9 +183,9 @@ class pdf_sirocco extends ModelePDFDeliveryOrder
for ($i = 0 ; $i < $nblines ; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
diff --git a/htdocs/core/modules/livraison/pdf/pdf_typhon.modules.php b/htdocs/core/modules/livraison/pdf/pdf_typhon.modules.php
index 9cc0de35648..b9cfc5ea909 100644
--- a/htdocs/core/modules/livraison/pdf/pdf_typhon.modules.php
+++ b/htdocs/core/modules/livraison/pdf/pdf_typhon.modules.php
@@ -240,9 +240,9 @@ class pdf_typhon extends ModelePDFDeliveryOrder
for ($i = 0 ; $i < $nblines ; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot-50); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
diff --git a/htdocs/core/modules/propale/doc/pdf_azur.modules.php b/htdocs/core/modules/propale/doc/pdf_azur.modules.php
index e4bed7e2883..d7e4cd7e538 100644
--- a/htdocs/core/modules/propale/doc/pdf_azur.modules.php
+++ b/htdocs/core/modules/propale/doc/pdf_azur.modules.php
@@ -262,9 +262,9 @@ class pdf_azur extends ModelePDFPropales
for ($i = 0 ; $i < $nblignes ; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
diff --git a/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php b/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
index 7eeddd1f856..058cd1ffab8 100644
--- a/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
+++ b/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
@@ -109,7 +109,7 @@ class doc_generic_odt extends ModeleThirdPartyDoc
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
else
{
- $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt');
+ $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt','','name',SORT_ASC,0,true); // Disable hook for the moment
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
}
}
diff --git a/htdocs/core/modules/supplier_invoice/pdf/pdf_canelle.modules.php b/htdocs/core/modules/supplier_invoice/pdf/pdf_canelle.modules.php
index 75cd1c17385..01649837213 100755
--- a/htdocs/core/modules/supplier_invoice/pdf/pdf_canelle.modules.php
+++ b/htdocs/core/modules/supplier_invoice/pdf/pdf_canelle.modules.php
@@ -259,9 +259,9 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
for ($i = 0 ; $i < $nblignes ; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();
diff --git a/htdocs/core/modules/supplier_order/pdf/pdf_muscadet.modules.php b/htdocs/core/modules/supplier_order/pdf/pdf_muscadet.modules.php
index a0fe3c05aea..bdd23c5b1da 100644
--- a/htdocs/core/modules/supplier_order/pdf/pdf_muscadet.modules.php
+++ b/htdocs/core/modules/supplier_order/pdf/pdf_muscadet.modules.php
@@ -271,9 +271,9 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
for ($i = 0 ; $i < $nblignes ; $i++)
{
$curY = $nexY;
- $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
-
- $pdf->setTopMargin($tab_top_newpage);
+ $pdf->SetFont('','', $default_font_size - 1); // Into loop to work with multipage
+
+ $pdf->setTopMargin($tab_top_newpage);
$pdf->setPageOrientation('', 1, $this->marge_basse+$heightforfooter+$heightforinfotot); // The only function to edit the bottom margin of current page to set it.
$pageposbefore=$pdf->getPage();