diff --git a/htdocs/contrat/fiche.php b/htdocs/contrat/fiche.php
index 0b6eee5c676..51c5dc9fd41 100644
--- a/htdocs/contrat/fiche.php
+++ b/htdocs/contrat/fiche.php
@@ -709,12 +709,12 @@ else
print '';
print img_object($langs->trans("ShowService"),"service").' '.$objp->ref.'';
print $objp->label?' - '.$objp->label:'';
- if ($objp->description) print '
'.stripslashes(nl2br($objp->description));
+ if ($objp->description) print '
'.nl2br($objp->description);
print '';
}
else
{
- print "
".stripslashes(nl2br($objp->description))." | \n";
+ print "".nl2br($objp->description)." | \n";
}
// TVA
print ''.$objp->tva_tx.'% | ';
diff --git a/htdocs/contrat/index.php b/htdocs/contrat/index.php
index 1a981407f05..7bd5d418a4b 100644
--- a/htdocs/contrat/index.php
+++ b/htdocs/contrat/index.php
@@ -107,8 +107,9 @@ $sql.= ' sum('.$db->ifsql("cd.statut=4 AND (cd.date_fin_validite IS NULL OR cd.d
$sql.= ' sum('.$db->ifsql("cd.statut=5",1,0).') as nb_closed,';
$sql.= " c.rowid as cid, c.ref, c.datec, c.statut, s.nom, s.idp as sidp";
if (!$user->rights->commercial->client->voir && !$socid) $sql .= ", sc.fk_soc, sc.fk_user";
-$sql.= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."contrat as c";
-if (!$user->rights->commercial->client->voir && !$socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
+$sql.= " FROM ".MAIN_DB_PREFIX."societe as s,";
+if (!$user->rights->commercial->client->voir && !$socid) $sql .= " ".MAIN_DB_PREFIX."societe_commerciaux as sc,";
+$sql.= " ".MAIN_DB_PREFIX."contrat as c";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."contratdet as cd ON c.rowid = cd.fk_contrat";
$sql.= " WHERE c.fk_soc = s.idp ";
if (!$user->rights->commercial->client->voir && !$socid) $sql .= " AND s.idp = sc.fk_soc AND sc.fk_user = " .$user->id;