diff --git a/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php b/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php index edb2a78818c..cceb6310dc2 100644 --- a/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php +++ b/htdocs/contact/canvas/default/tpl/contactcard_create.tpl.php @@ -39,7 +39,7 @@ echo $this->control->tpl['ajax_selectcountry']; ?>
"> - + control->tpl['company_id']) { ?> diff --git a/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php b/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php index 5c06b1d1549..cf193e25274 100644 --- a/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php +++ b/htdocs/contact/canvas/default/tpl/contactcard_edit.tpl.php @@ -39,7 +39,7 @@ echo $this->control->tpl['ajax_selectcountry'];
"> - + diff --git a/htdocs/core/actions_massactions.inc.php b/htdocs/core/actions_massactions.inc.php index fdd4d1a69fd..e340f864554 100644 --- a/htdocs/core/actions_massactions.inc.php +++ b/htdocs/core/actions_massactions.inc.php @@ -1053,9 +1053,9 @@ if (!$error && $massaction == "builddoc" && $permissiontoread && !GETPOST('butto if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) { $newlang = GETPOST('lang_id', 'aZ09'); } - if ($conf->global->MAIN_MULTILANGS && empty($newlang)) { - $newlang = $objecttmp->thirdparty->default_lang; - } + //elseif ($conf->global->MAIN_MULTILANGS && empty($newlang) && is_object($objecttmp->thirdparty)) { // In massaction $objecttmp->thirdparty can have several values + // $newlang = $objecttmp->thirdparty->default_lang; + //} if (!empty($newlang)) { $outputlangs = new Translate("", $conf); $outputlangs->setDefaultLang($newlang); diff --git a/htdocs/core/tpl/admin_extrafields_add.tpl.php b/htdocs/core/tpl/admin_extrafields_add.tpl.php index ddcdfdf9e4b..d9c0f650395 100644 --- a/htdocs/core/tpl/admin_extrafields_add.tpl.php +++ b/htdocs/core/tpl/admin_extrafields_add.tpl.php @@ -138,7 +138,7 @@ $listofexamplesforlink = 'Societe:societe/class/societe.class.php
Contact:con " method="post"> - + diff --git a/htdocs/core/tpl/contacts.tpl.php b/htdocs/core/tpl/contacts.tpl.php index 511c03a931b..32ff4385f3a 100644 --- a/htdocs/core/tpl/contacts.tpl.php +++ b/htdocs/core/tpl/contacts.tpl.php @@ -100,7 +100,7 @@ if ($permission) { if (empty($hideaddcontactforuser)) { ?> " /> + @@ -130,7 +130,7 @@ if ($permission) { ?> " /> + diff --git a/htdocs/core/tpl/passwordforgotten.tpl.php b/htdocs/core/tpl/passwordforgotten.tpl.php index 6e890f06e80..9e0a222725b 100644 --- a/htdocs/core/tpl/passwordforgotten.tpl.php +++ b/htdocs/core/tpl/passwordforgotten.tpl.php @@ -91,7 +91,7 @@ $(document).ready(function () {
- + diff --git a/htdocs/product/canvas/product/tpl/card_create.tpl.php b/htdocs/product/canvas/product/tpl/card_create.tpl.php index b862eddefc5..5d39b55ff76 100644 --- a/htdocs/product/canvas/product/tpl/card_create.tpl.php +++ b/htdocs/product/canvas/product/tpl/card_create.tpl.php @@ -39,7 +39,7 @@ print dol_get_fiche_head(''); " method="post"> - + diff --git a/htdocs/product/canvas/product/tpl/card_edit.tpl.php b/htdocs/product/canvas/product/tpl/card_edit.tpl.php index 21f2edefc2d..2e04f660084 100644 --- a/htdocs/product/canvas/product/tpl/card_edit.tpl.php +++ b/htdocs/product/canvas/product/tpl/card_edit.tpl.php @@ -38,7 +38,7 @@ dol_htmloutput_errors($object->error, $object->errors); ?> " method="post"> - + diff --git a/htdocs/product/canvas/service/tpl/card_create.tpl.php b/htdocs/product/canvas/service/tpl/card_create.tpl.php index ce3c4f5cc58..73f79b6efdb 100644 --- a/htdocs/product/canvas/service/tpl/card_create.tpl.php +++ b/htdocs/product/canvas/service/tpl/card_create.tpl.php @@ -39,7 +39,7 @@ print dol_get_fiche_head(''); " method="post"> - + diff --git a/htdocs/product/canvas/service/tpl/card_edit.tpl.php b/htdocs/product/canvas/service/tpl/card_edit.tpl.php index 4906b0dcf2c..a656d749a4b 100644 --- a/htdocs/product/canvas/service/tpl/card_edit.tpl.php +++ b/htdocs/product/canvas/service/tpl/card_edit.tpl.php @@ -38,7 +38,7 @@ dol_htmloutput_errors($object->error, $object->errors); ?> " method="post"> - + diff --git a/htdocs/ticket/card.php b/htdocs/ticket/card.php index f2edf617ff5..1831a4078c5 100644 --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -1329,10 +1329,14 @@ if ($action == 'create' || $action == 'presend') { $newlang = ''; if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) { $newlang = GETPOST('lang_id', 'aZ09'); - } - if ($conf->global->MAIN_MULTILANGS && empty($newlang) && is_object($object->thirdparty)) { + } elseif ($conf->global->MAIN_MULTILANGS && empty($newlang) && is_object($object->thirdparty)) { $newlang = $object->thirdparty->default_lang; } + if (!empty($newlang)) { + $outputlangs = new Translate("", $conf); + $outputlangs->setDefaultLang($newlang); + } + $arrayoffamiliestoexclude = array('objectamount'); $action = 'add_message'; // action to use to post the message @@ -1341,7 +1345,7 @@ if ($action == 'create' || $action == 'presend') { // Substitution array $morehtmlright = ''; $help = ""; - $substitutionarray = getCommonSubstitutionArray($newlang, 0, $arrayoffamiliestoexclude, $object); + $substitutionarray = getCommonSubstitutionArray($outputlangs, 0, $arrayoffamiliestoexclude, $object); if ($object->fk_soc > 0) { $substitutionarray['__THIRDPARTY_NAME__'] = $object->thirdparty->name; }