From 1dfeaed082ffaef202b92171ac1a5c9b1e7b1c13 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 11 Aug 2009 20:38:04 +0000 Subject: [PATCH] Remove the trim to allow user to use spaces in its free text. This allow to place text where he wants (begin, center, two third...) --- htdocs/admin/bank.php | 4 ++-- htdocs/admin/commande.php | 4 ++-- htdocs/admin/facture.php | 4 ++-- htdocs/admin/livraison.php | 6 +++--- htdocs/admin/propale.php | 4 ++-- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/htdocs/admin/bank.php b/htdocs/admin/bank.php index 0c06f9f429c..153819287ca 100644 --- a/htdocs/admin/bank.php +++ b/htdocs/admin/bank.php @@ -45,7 +45,7 @@ $typeconst=array('yesno','texte','chaine'); if ($_POST["action"] == 'set_BANK_CHEQUERECEIPT_FREE_TEXT') { - dolibarr_set_const($db, "BANK_CHEQUERECEIPT_FREE_TEXT",trim($_POST["BANK_CHEQUERECEIPT_FREE_TEXT"]),'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "BANK_CHEQUERECEIPT_FREE_TEXT",$_POST["BANK_CHEQUERECEIPT_FREE_TEXT"],'chaine',0,'',$conf->entity); } @@ -77,7 +77,7 @@ print ''; print ''; print ''; print $langs->trans("FreeLegalTextOnChequeReceipts").' ('.$langs->trans("AddCRIfTooLong").')
'; -print ''; +print ''; print ''; print ''; print "\n"; diff --git a/htdocs/admin/commande.php b/htdocs/admin/commande.php index 4d75aeeabc8..777f188e2e3 100644 --- a/htdocs/admin/commande.php +++ b/htdocs/admin/commande.php @@ -154,7 +154,7 @@ if ($_POST["action"] == 'set_COMMANDE_DRAFT_WATERMARK') if ($_POST["action"] == 'set_COMMANDE_FREE_TEXT') { - dolibarr_set_const($db, "COMMANDE_FREE_TEXT",trim($_POST["COMMANDE_FREE_TEXT"]),'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "COMMANDE_FREE_TEXT",$_POST["COMMANDE_FREE_TEXT"],'chaine',0,'',$conf->entity); } if ($_POST["action"] == 'setvalidorder') @@ -466,7 +466,7 @@ print ''; print ''; print ''; print $langs->trans("FreeLegalTextOnOrders").' ('.$langs->trans("AddCRIfTooLong").')
'; -print ''; +print ''; print ''; print ''; print "\n"; diff --git a/htdocs/admin/facture.php b/htdocs/admin/facture.php index e7596223d57..dd49954c277 100644 --- a/htdocs/admin/facture.php +++ b/htdocs/admin/facture.php @@ -164,7 +164,7 @@ if ($_POST["action"] == 'set_FACTURE_DRAFT_WATERMARK') if ($_POST["action"] == 'set_FACTURE_FREE_TEXT') { - dolibarr_set_const($db, "FACTURE_FREE_TEXT",trim($_POST["FACTURE_FREE_TEXT"]),'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "FACTURE_FREE_TEXT",$_POST["FACTURE_FREE_TEXT"],'chaine',0,'',$conf->entity); } if ($_POST["action"] == 'setforcedate') @@ -622,7 +622,7 @@ print ''; print ''; print ''; print $langs->trans("FreeLegalTextOnInvoices").' ('.$langs->trans("AddCRIfTooLong").')
'; -print ''; +print ''; print ''; print ''; print "\n"; diff --git a/htdocs/admin/livraison.php b/htdocs/admin/livraison.php index 8415a27535e..efe02973d56 100644 --- a/htdocs/admin/livraison.php +++ b/htdocs/admin/livraison.php @@ -104,7 +104,7 @@ if ($_GET["action"] == 'del') $sql.= " WHERE nom = '".$_GET["value"]; $sql.= " AND type = '".$type."'"; $sql.= " AND entity = ".$conf->entity; - + if ($db->query($sql)) { @@ -141,7 +141,7 @@ if ($_GET["action"] == 'setdoc') if ($_POST["action"] == 'set_DELIVERY_FREE_TEXT') { - dolibarr_set_const($db, "DELIVERY_FREE_TEXT",trim($_POST["DELIVERY_FREE_TEXT"]),'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "DELIVERY_FREE_TEXT",$_POST["DELIVERY_FREE_TEXT"],'chaine',0,'',$conf->entity); } if ($_GET["action"] == 'setmod') @@ -424,7 +424,7 @@ print ''; print ''; print ''; print $langs->trans("FreeLegalTextOnDeliveryReceipts").' ('.$langs->trans("AddCRIfTooLong").')
'; -print ''; +print ''; print ''; print ''; print "\n"; diff --git a/htdocs/admin/propale.php b/htdocs/admin/propale.php index cab744ef8b7..346be15ce58 100644 --- a/htdocs/admin/propale.php +++ b/htdocs/admin/propale.php @@ -95,7 +95,7 @@ if ($_POST["action"] == 'set_PROPALE_DRAFT_WATERMARK') if ($_POST["action"] == 'set_PROPALE_FREE_TEXT') { - dolibarr_set_const($db, "PROPALE_FREE_TEXT",trim($_POST["PROPALE_FREE_TEXT"]),'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "PROPALE_FREE_TEXT",$_POST["PROPALE_FREE_TEXT"],'chaine',0,'',$conf->entity); } if ($_POST["action"] == 'setnbprod') @@ -472,7 +472,7 @@ print ''; print ''; print ''; print $langs->trans("FreeLegalTextOnProposal").' ('.$langs->trans("AddCRIfTooLong").')
'; -print ''; +print ''; print ''; print ''; print "\n";