diff --git a/htdocs/admin/boxes.php b/htdocs/admin/boxes.php index 58c07b5ca3e..ca90c836929 100644 --- a/htdocs/admin/boxes.php +++ b/htdocs/admin/boxes.php @@ -222,7 +222,7 @@ llxHeader('', $langs->trans("Boxes")); print load_fiche_titre($langs->trans("Boxes"), '', 'title_setup'); -print $langs->trans("BoxesDesc")." ".$langs->trans("OnlyActiveElementsAreShown")."
\n"; +print ''.$langs->trans("BoxesDesc")." ".$langs->trans("OnlyActiveElementsAreShown")."
\n"; /* * Search for the default active boxes for each possible position diff --git a/htdocs/admin/delais.php b/htdocs/admin/delais.php index 47f668f69c3..d69a14deb2e 100644 --- a/htdocs/admin/delais.php +++ b/htdocs/admin/delais.php @@ -174,8 +174,8 @@ llxHeader(); print load_fiche_titre($langs->trans("DelaysOfToleranceBeforeWarning"), '', 'title_setup'); -print $langs->transnoentities("DelaysOfToleranceDesc", img_warning()); -print " ".$langs->trans("OnlyActiveElementsAreShown", DOL_URL_ROOT.'/admin/modules.php')."
\n"; +print ''.$langs->transnoentities("DelaysOfToleranceDesc", img_warning()); +print " ".$langs->trans("OnlyActiveElementsAreShown", DOL_URL_ROOT.'/admin/modules.php')."
\n"; print "
\n"; $countrynotdefined=''.$langs->trans("ErrorSetACountryFirst").' ('.$langs->trans("SeeAbove").')'; diff --git a/htdocs/admin/ihm.php b/htdocs/admin/ihm.php index df8929fd8fe..dfbb548f5e0 100644 --- a/htdocs/admin/ihm.php +++ b/htdocs/admin/ihm.php @@ -222,7 +222,6 @@ $formadmin=new FormAdmin($db); print load_fiche_titre($langs->trans("GUISetup"), '', 'title_setup'); print ''.$langs->trans("DisplayDesc")."
\n"; -print "
\n"; //WYSIWYG Editor require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php'; diff --git a/htdocs/admin/limits.php b/htdocs/admin/limits.php index c9e69cc469e..ea19b7034a6 100644 --- a/htdocs/admin/limits.php +++ b/htdocs/admin/limits.php @@ -90,7 +90,7 @@ llxHeader(); print load_fiche_titre($langs->trans("LimitsSetup"), '', 'title_setup'); -print $langs->trans("LimitsDesc")."
\n"; +print ''.$langs->trans("LimitsDesc")."
\n"; print "
\n"; if ($action == 'edit') diff --git a/htdocs/admin/menus.php b/htdocs/admin/menus.php index b334ccadf45..4187c4d3eb4 100644 --- a/htdocs/admin/menus.php +++ b/htdocs/admin/menus.php @@ -159,116 +159,63 @@ print ''.$langs->trans("MenusDesc")."
\n"; print "
\n"; -if ($action == 'edit') -{ - clearstatcache(); +clearstatcache(); - // Gestionnaires de menu - print ''; - print ''; - print ''; - print ''; - print ''; +// Gestionnaires de menu +print '
'.$langs->trans("Menu").''; - print $form->textwithpicto($langs->trans("InternalUsers"), $langs->trans("InternalExternalDesc")); - print ''; - print $form->textwithpicto($langs->trans("ExternalUsers"), $langs->trans("InternalExternalDesc")); - print '
'; +print ''; +print ''; +print ''; +print ''; - // Menu top - print ''; - print ''; - print ''; - print ''; +// Menu top +print ''; +print ''; +print ''; +print ''; - // Menu smartphone - print ''; - print ''; - print ''; - print ''; +// Menu smartphone +print ''; +print '
'.$langs->trans("Menu").''; +print $form->textwithpicto($langs->trans("InternalUsers"), $langs->trans("InternalExternalDesc")); +print ''; +print $form->textwithpicto($langs->trans("ExternalUsers"), $langs->trans("InternalExternalDesc")); +print '
'.$langs->trans("DefaultMenuManager").''; - $formadmin->select_menu(empty($conf->global->MAIN_MENU_STANDARD_FORCED)?$conf->global->MAIN_MENU_STANDARD:$conf->global->MAIN_MENU_STANDARD_FORCED, 'MAIN_MENU_STANDARD', $dirstandard, empty($conf->global->MAIN_MENU_STANDARD_FORCED)?'':' disabled'); - print ''; - $formadmin->select_menu(empty($conf->global->MAIN_MENUFRONT_STANDARD_FORCED)?$conf->global->MAIN_MENUFRONT_STANDARD:$conf->global->MAIN_MENUFRONT_STANDARD_FORCED, 'MAIN_MENUFRONT_STANDARD', $dirstandard, empty($conf->global->MAIN_MENUFRONT_STANDARD_FORCED)?'':' disabled'); - print '
'.$langs->trans("DefaultMenuManager").''; +$formadmin->select_menu(empty($conf->global->MAIN_MENU_STANDARD_FORCED)?$conf->global->MAIN_MENU_STANDARD:$conf->global->MAIN_MENU_STANDARD_FORCED, 'MAIN_MENU_STANDARD', $dirstandard, empty($conf->global->MAIN_MENU_STANDARD_FORCED)?'':' disabled'); +print ''; +$formadmin->select_menu(empty($conf->global->MAIN_MENUFRONT_STANDARD_FORCED)?$conf->global->MAIN_MENUFRONT_STANDARD:$conf->global->MAIN_MENUFRONT_STANDARD_FORCED, 'MAIN_MENUFRONT_STANDARD', $dirstandard, empty($conf->global->MAIN_MENUFRONT_STANDARD_FORCED)?'':' disabled'); +print '
'.$langs->trans("DefaultMenuSmartphoneManager").''; - $formadmin->select_menu(empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED)?$conf->global->MAIN_MENU_SMARTPHONE:$conf->global->MAIN_MENU_SMARTPHONE_FORCED, 'MAIN_MENU_SMARTPHONE', array_merge($dirstandard, $dirsmartphone), empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED)?'':' disabled'); - print ''; - $formadmin->select_menu(empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)?$conf->global->MAIN_MENUFRONT_SMARTPHONE:$conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED, 'MAIN_MENUFRONT_SMARTPHONE', array_merge($dirstandard, $dirsmartphone), empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)?'':' disabled'); - print '
'.$langs->trans("DefaultMenuSmartphoneManager").''; +$formadmin->select_menu(empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED)?$conf->global->MAIN_MENU_SMARTPHONE:$conf->global->MAIN_MENU_SMARTPHONE_FORCED, 'MAIN_MENU_SMARTPHONE', array_merge($dirstandard, $dirsmartphone), empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED)?'':' disabled'); - print '
'; -} -else -{ - // Gestionnaires de menu - print ''; - print ''; - print ''; - print ''; - print ''; - - - print ''; - print ''; - print ''; - print ''; - - - print ''; - print ''; - print ''; - print ''; - print ''; - - print '
'.$langs->trans("Menu").''; - print $form->textwithpicto($langs->trans("InternalUsers"), $langs->trans("InternalExternalDesc")); - print ''; - print $form->textwithpicto($langs->trans("ExternalUsers"), $langs->trans("InternalExternalDesc")); - print '
'.$langs->trans("DefaultMenuManager").''; - $filelib=preg_replace('/.php$/i', '', (empty($conf->global->MAIN_MENU_STANDARD_FORCED)?$conf->global->MAIN_MENU_STANDARD:$conf->global->MAIN_MENU_STANDARD_FORCED)); - print $filelib; - print ''; - $filelib=preg_replace('/.php$/i', '', (empty($conf->global->MAIN_MENUFRONT_STANDARD_FORCED)?$conf->global->MAIN_MENUFRONT_STANDARD:$conf->global->MAIN_MENUFRONT_STANDARD_FORCED)); - print $filelib; - print '
'.$langs->trans("DefaultMenuSmartphoneManager").''; - $filelib=preg_replace('/.php$/i', '', (empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED)?$conf->global->MAIN_MENU_SMARTPHONE:$conf->global->MAIN_MENU_SMARTPHONE_FORCED)); - print $filelib; - if (! empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED) && preg_match('/smartphone/', $conf->global->MAIN_MENU_SMARTPHONE_FORCED) +if (! empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED) && preg_match('/smartphone/', $conf->global->MAIN_MENU_SMARTPHONE_FORCED) || (empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED) && ! empty($conf->global->MAIN_MENU_SMARTPHONE) && preg_match('/smartphone/', $conf->global->MAIN_MENU_SMARTPHONE))) - { - print ' '.img_warning($langs->transnoentitiesnoconv("ThisForceAlsoTheme")); - } - print ''; - $filelib=preg_replace('/.php$/i', '', (empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)?$conf->global->MAIN_MENUFRONT_SMARTPHONE:$conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)); - print $filelib; - if (! empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED) && preg_match('/smartphone/', $conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED) - || (empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED) && ! empty($conf->global->MAIN_MENU_SMARTPHONE) && preg_match('/smartphone/', $conf->global->MAIN_MENUFRONT_SMARTPHONE))) - { - print ' '.img_warning($langs->transnoentitiesnoconv("ThisForceAlsoTheme")); - } - print '
'; +{ + print ' '.img_warning($langs->transnoentitiesnoconv("ThisForceAlsoTheme")); } +print ''; +print ''; +$formadmin->select_menu(empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)?$conf->global->MAIN_MENUFRONT_SMARTPHONE:$conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED, 'MAIN_MENUFRONT_SMARTPHONE', array_merge($dirstandard, $dirsmartphone), empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)?'':' disabled'); + +if (! empty($conf->global->MAIN_MENU_SMARTPHONE_FORCED) && preg_match('/smartphone/', $conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED) + || (empty($conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED) && ! empty($conf->global->MAIN_MENU_SMARTPHONE) && preg_match('/smartphone/', $conf->global->MAIN_MENUFRONT_SMARTPHONE))) +{ + print ' '.img_warning($langs->transnoentitiesnoconv("ThisForceAlsoTheme")); +} + +print ''; +print ''; + +print ''; + dol_fiche_end(); - -if ($action == 'edit') -{ - print '
'; - print ''; - print '       '; - print ''; - print '
'; -} +print '
'; +print ''; +print '
'; print ''; - -if ($action != 'edit') -{ - print '
'; - print ''.$langs->trans("Modify").''; - print '
'; -} - // End of page llxFooter(); $db->close(); diff --git a/htdocs/admin/pdf.php b/htdocs/admin/pdf.php index a8c1aa41b5f..e9346f49a3a 100644 --- a/htdocs/admin/pdf.php +++ b/htdocs/admin/pdf.php @@ -123,460 +123,244 @@ print "
\n"; $noCountryCode = (empty($mysoc->country_code) ? true : false); -if ($action == 'edit') // Edit +print '
'; +print ''; +print ''; + +clearstatcache(); + + +// Misc options +print load_fiche_titre($langs->trans("DictionaryPaperFormat"), '', ''); + +print '
'; +print ''; +print ''; + +$selected=$conf->global->MAIN_PDF_FORMAT; +if (empty($selected)) $selected=dol_getDefaultFormat(); + +// Show pdf format + +print ''; + +print ''; +print ''; +print ''; +print ''; + +print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("DictionaryPaperFormat").''; +print $formadmin->select_paper_format($selected, 'MAIN_PDF_FORMAT'); +print '
'.$langs->trans("MAIN_PDF_MARGIN_LEFT").''; +print ''; +print '
'.$langs->trans("MAIN_PDF_MARGIN_RIGHT").''; +print ''; +print '
'.$langs->trans("MAIN_PDF_MARGIN_TOP").''; +print ''; +print '
'.$langs->trans("MAIN_PDF_MARGIN_BOTTOM").''; +print ''; +print '
'; +print '
'; + +print '
'; + + +// Addresses +print load_fiche_titre($langs->trans("PDFAddressForging"), '', ''); + +print '
'; +print ''; +print ''; + +// Hide VAT Intra on address + +print ''; + +// Show prof id in address into pdf +for($i=1; $i<=6; $i++) { - print ''; - print ''; - print ''; - - clearstatcache(); - - - // Misc options - print load_fiche_titre($langs->trans("DictionaryPaperFormat"), '', ''); - - print '
'; - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("ShowVATIntaInAddress").''; +print $form->selectyesno('MAIN_TVAINTRA_NOT_IN_ADDRESS', (! empty($conf->global->MAIN_TVAINTRA_NOT_IN_ADDRESS))?$conf->global->MAIN_TVAINTRA_NOT_IN_ADDRESS:0, 1); +print '
'; - print ''; - - $selected=$conf->global->MAIN_PDF_FORMAT; - if (empty($selected)) $selected=dol_getDefaultFormat(); - - // Show pdf format - - print ''; - - print ''; - print ''; - print ''; - print ''; - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("DictionaryPaperFormat").''; - print $formadmin->select_paper_format($selected, 'MAIN_PDF_FORMAT'); - print '
'.$langs->trans("MAIN_PDF_MARGIN_LEFT").''; - print ''; - print '
'.$langs->trans("MAIN_PDF_MARGIN_RIGHT").''; - print ''; - print '
'.$langs->trans("MAIN_PDF_MARGIN_TOP").''; - print ''; - print '
'.$langs->trans("MAIN_PDF_MARGIN_BOTTOM").''; - print ''; - print '
'; - print '
'; - - print '
'; - - - // Addresses - print load_fiche_titre($langs->trans("PDFAddressForging"), '', ''); - - print '
'; - print ''; - print ''; - - // Hide VAT Intra on address - - print ''; - - // Show prof id in address into pdf - for($i=1; $i<=6; $i++) - { - if (! $noCountryCode) - { - $pid=$langs->transcountry("ProfId".$i, $mysoc->country_code); - if ($pid == '-') $pid=false; - } - else - { - $pid = img_warning().' '.$langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("CompanyCountry")).''; - } - if ($pid) - { - print ''; - } - } - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("ShowVATIntaInAddress").''; - print $form->selectyesno('MAIN_TVAINTRA_NOT_IN_ADDRESS', (! empty($conf->global->MAIN_TVAINTRA_NOT_IN_ADDRESS))?$conf->global->MAIN_TVAINTRA_NOT_IN_ADDRESS:0, 1); - print '
'.$langs->trans("ShowProfIdInAddress").' - '.$pid.''; - $keyforconstant = 'MAIN_PROFID'.$i.'_IN_ADDRESS'; - print $form->selectyesno($keyforconstant, isset($conf->global->$keyforconstant)?$conf->global->$keyforconstant:0, 1, $noCountryCode); - print '
'; - print '
'; - - - print '
'; - - - // Localtaxes - $locales =''; - $text=''; - if ($mysoc->useLocalTax(1) || $mysoc->useLocalTax(2)) - { - if ($mysoc->useLocalTax(1)) - { - $locales = $langs->transcountry("LT1", $mysoc->country_code); - $text ='' . $langs->trans("HideLocalTaxOnPDF", $langs->transcountry("LT1", $mysoc->country_code)) . ''; - $text.= $form->selectyesno('MAIN_PDF_MAIN_HIDE_SECOND_TAX', (!empty($conf->global->MAIN_PDF_MAIN_HIDE_SECOND_TAX)) ? $conf->global->MAIN_PDF_MAIN_HIDE_SECOND_TAX : 0, 1); - $text .= ''; - } - - if ($mysoc->useLocalTax(2)) - { - $locales.=($locales?' & ':'').$langs->transcountry("LT2", $mysoc->country_code); - - $text.= '' . $langs->trans("HideLocalTaxOnPDF", $langs->transcountry("LT2", $mysoc->country_code)) . ''; - $text.= $form->selectyesno('MAIN_PDF_MAIN_HIDE_THIRD_TAX', (!empty($conf->global->MAIN_PDF_MAIN_HIDE_THIRD_TAX)) ? $conf->global->MAIN_PDF_MAIN_HIDE_THIRD_TAX : 0, 1); - $text.= ''; - } - } - - $title = $langs->trans("PDFRulesForSalesTax"); - if ($mysoc->useLocalTax(1) || $mysoc->useLocalTax(2)) - { - $title.=' - '.$langs->trans("PDFLocaltax", $locales); - } - - print load_fiche_titre($title, '', ''); - - print ''; - print ''; - - // Hide any information on Sale tax / VAT - - print ''; - - // Locataxes - print $text; - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("HideAnyVATInformationOnPDF").''; - print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))?$conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT:0, 1); - print '
'; - print '
'; - - - // Other - print load_fiche_titre($langs->trans("Other"), '', ''); - - print '
'; - print ''; - print ''; - - //Desc - - print ''; - - //Ref - - print ''; - - //Details - - print ''; - - //Invert sender and recipient - - print ''; - - // Place customer adress to the ISO location - - print ''; - - - print ''; - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("HideDescOnPDF").''; - print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_DESC', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DESC))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DESC:0, 1); - print '
'.$langs->trans("HideRefOnPDF").''; - print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_REF', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_REF))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_REF:0, 1); - print '
'.$langs->trans("HideDetailsOnPDF").''; - print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS:0, 1); - print '
'.$langs->trans("SwapSenderAndRecipientOnPDF").''; - print $form->selectyesno('MAIN_INVERT_SENDER_RECIPIENT', (! empty($conf->global->MAIN_INVERT_SENDER_RECIPIENT))?$conf->global->MAIN_INVERT_SENDER_RECIPIENT:0, 1); - print '
'.$langs->trans("PlaceCustomerAddressToIsoLocation").''; - print $form->selectyesno('MAIN_PDF_USE_ISO_LOCATION', (! empty($conf->global->MAIN_PDF_USE_ISO_LOCATION))?$conf->global->MAIN_PDF_USE_ISO_LOCATION:0, 1); - print '
'.$langs->trans("ShowDetailsInPDFPageFoot").''; - print $form->selectarray('MAIN_GENERATE_DOCUMENTS_SHOW_FOOT_DETAILS', $arraydetailsforpdffoot, $conf->global->MAIN_GENERATE_DOCUMENTS_SHOW_FOOT_DETAILS); - print '
'; - print '
'; - - print '
'; - print ''; - print '   '; - print ''; - print '
'; - - print '
'; - print '
'; -} -else // Show -{ - // Misc options - print load_fiche_titre($langs->trans("DictionaryPaperFormat"), '', ''); - - - print '
'; - print ''; - print ''; - - // Show pdf format - - print ''; - - print ''; - print ''; - print ''; - print ''; - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("DictionaryPaperFormat").''; - - $pdfformatlabel=''; - if (empty($conf->global->MAIN_PDF_FORMAT)) - { - include_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; - $pdfformatlabel=dol_getDefaultFormat(); - } - else $pdfformatlabel=$conf->global->MAIN_PDF_FORMAT; - if (! empty($pdfformatlabel)) - { - $sql="SELECT code, label, width, height, unit FROM ".MAIN_DB_PREFIX."c_paper_format"; - $sql.=" WHERE code LIKE '%".$db->escape($pdfformatlabel)."%'"; - - $resql=$db->query($sql); - if ($resql) - { - $obj=$db->fetch_object($resql); - $paperKey = $langs->trans('PaperFormat'.$obj->code); - $unitKey = $langs->trans('SizeUnit'.$obj->unit); - $pdfformatlabel = ($paperKey == 'PaperFormat'.$obj->code ? $obj->label : $paperKey).' - '.round($obj->width).'x'.round($obj->height).' '.($unitKey == 'SizeUnit'.$obj->unit ? $obj->unit : $unitKey); - } - } - print $pdfformatlabel; - print '
'.$langs->trans("MAIN_PDF_MARGIN_LEFT").''; - print empty($conf->global->MAIN_PDF_MARGIN_LEFT)?10:$conf->global->MAIN_PDF_MARGIN_LEFT; - print '
'.$langs->trans("MAIN_PDF_MARGIN_RIGHT").''; - print empty($conf->global->MAIN_PDF_MARGIN_RIGHT)?10:$conf->global->MAIN_PDF_MARGIN_RIGHT; - print '
'.$langs->trans("MAIN_PDF_MARGIN_TOP").''; - print empty($conf->global->MAIN_PDF_MARGIN_TOP)?10:$conf->global->MAIN_PDF_MARGIN_TOP; - print '
'.$langs->trans("MAIN_PDF_MARGIN_BOTTOM").''; - print empty($conf->global->MAIN_PDF_MARGIN_BOTTOM)?10:$conf->global->MAIN_PDF_MARGIN_BOTTOM; - print '
'; - print '
'; - - print '
'; - - print load_fiche_titre($langs->trans("PDFAddressForging"), '', ''); - - print '
'; - print ''; - print ''; - - // Hide Intra VAT on address - - print ''; - - // Show prof id in address into pdf - for ($i=1; $i<=6; $i++) + if (! $noCountryCode) { - if (! $noCountryCode) - { - $pid=$langs->transcountry("ProfId".$i, $mysoc->country_code); - if ($pid == '-') $pid=false; - } - else - { - $pid = img_warning().' '.$langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("CompanyCountry")).''; - } - if ($pid) - { - print ''; - } - } - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("ShowVATIntaInAddress").''; - print yn($conf->global->MAIN_TVAINTRA_NOT_IN_ADDRESS, 1); - print '
'.$langs->trans("ShowProfIdInAddress").' - '.$pid.''; - $keyforconstant = 'MAIN_PROFID'.$i.'_IN_ADDRESS'; - print yn($conf->global->$keyforconstant, 1); - print '
'."\n"; - print '
'; - - print '
'; - - // Localtaxes - $locales =''; - $text=''; - if ($mysoc->useLocalTax(1) || $mysoc->useLocalTax(2)) - { - if ($mysoc->useLocalTax(1)) - { - $locales = $langs->transcountry("LT1", $mysoc->country_code); - $text ='' . $langs->trans("HideLocalTaxOnPDF", $langs->transcountry("LT1", $mysoc->country_code)) . ''; - $text .= yn($conf->global->MAIN_PDF_MAIN_HIDE_SECOND_TAX, 1); - $text .= ''; - } - - if ($mysoc->useLocalTax(2)) - { - $locales.=($locales?' & ':'').$langs->transcountry("LT2", $mysoc->country_code); - - $text.= '' . $langs->trans("HideLocalTaxOnPDF", $langs->transcountry("LT2", $mysoc->country_code)) . ''; - $text.= yn($conf->global->MAIN_PDF_MAIN_HIDE_THIRD_TAX, 1); - $text.= ''; - } - } - - // Sales TAX / VAT information - $title=$langs->trans("PDFRulesForSalesTax", $locales); - if ($mysoc->useLocalTax(1) || $mysoc->useLocalTax(2)) $title.=' - '.$langs->trans("PDFLocaltax", $locales); - - print load_fiche_titre($title, '', ''); - - print ''; - print ''; - - print ''; - - print $text; - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("HideAnyVATInformationOnPDF").''; - print yn($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT, 1); - print '
'; - print '
'; - - - // Other - print load_fiche_titre($langs->trans("Other"), '', ''); - - print '
'; - print ''; - print ''; - - // Encrypt and protect PDF - - print ''; - print ''; - print ''; - print '"; - - print ""; - print ''; - - // Hide Desc - - print ''; - - // Hide Ref - - print ''; - - // Hide Details - - print ''; - - // Invert sender and recipient - print ''; - - // Use French location - print ''; - - - print ''; - - print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'; - $text = $langs->trans("ProtectAndEncryptPdfFiles"); - $desc = $form->textwithpicto($text, $langs->transnoentities("ProtectAndEncryptPdfFilesDesc"), 1); - print $desc; - print ''; - if($conf->global->PDF_SECURITY_ENCRYPTION == 1) - { - print img_picto($langs->trans("Active"), 'tick'); - } - print ''; - if (empty($conf->global->PDF_SECURITY_ENCRYPTION)) - { - print ''.$langs->trans("Activate").''; + $pid=$langs->transcountry("ProfId".$i, $mysoc->country_code); + if ($pid == '-') $pid=false; } else { - print ''.$langs->trans("Disable").''; + $pid = img_warning().' '.$langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("CompanyCountry")).''; } - print "
'.$langs->trans("HideDescOnPDF").''; - print yn($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DESC, 1); - print '
'.$langs->trans("HideRefOnPDF").''; - print yn($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_REF, 1); - print '
'.$langs->trans("HideDetailsOnPDF").''; - print yn($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS, 1); - print '
'.$langs->trans("SwapSenderAndRecipientOnPDF").''; - print yn($conf->global->MAIN_INVERT_SENDER_RECIPIENT, 1); - print '
'.$langs->trans("PlaceCustomerAddressToIsoLocation").''; - print yn($conf->global->MAIN_PDF_USE_ISO_LOCATION, 1); - print '
'.$langs->trans("ShowDetailsInPDFPageFoot").''; - print $arraydetailsforpdffoot[($conf->global->MAIN_GENERATE_DOCUMENTS_SHOW_FOOT_DETAILS ? $conf->global->MAIN_GENERATE_DOCUMENTS_SHOW_FOOT_DETAILS : 0)]; - print '
'; - print '
'; - - - /* - * Library - */ - - print '
'; - print load_fiche_titre($langs->trans("Library"), '', ''); - - print '
'; - print ''."\n"; - - print ''."\n"; - print ''."\n"; - print ''."\n"; - print "\n"; - - print ''."\n"; - print ''."\n"; - print ''; } - if (class_exists('TCPDF')) - { - if ($i) print ' + '; - print 'TCPDF'; - print ' ('.@constant('TCPDF_PATH').')'; - $i++; - } - if (class_exists('FPDI')) - { - if ($i) print ' + '; - print 'FPDI'; - print ' ('.@constant('FPDI_PATH').')'; - $i++; - } - if (class_exists('TCPDI')) - { - if ($i) print ' + '; - print 'TCPDI'; - print ' ('.@constant('TCPDI_PATH').')'; - $i++; - } - print ''."\n"; - print ''."\n"; - - print "
'.$langs->trans("Name").''.$langs->trans("Value").'
'.$langs->trans("LibraryToBuildPDF").''; - $i=0; - $pdf=pdf_getInstance('A4'); - if (class_exists('FPDF') && ! class_exists('TCPDF')) + if ($pid) { - if ($i) print ' + '; - print 'FPDF'; - print ' ('.@constant('FPDF_PATH').')'; - $i++; + print '
'.$langs->trans("ShowProfIdInAddress").' - '.$pid.''; + $keyforconstant = 'MAIN_PROFID'.$i.'_IN_ADDRESS'; + print $form->selectyesno($keyforconstant, isset($conf->global->$keyforconstant)?$conf->global->$keyforconstant:0, 1, $noCountryCode); + print '
\n"; - print '
'; - - print '
'; - print ''.$langs->trans("Modify").''; - print '
'; - print '
'; } +print ''; +print ''; + + +print '
'; + + +// Localtaxes +$locales =''; +$text=''; +if ($mysoc->useLocalTax(1) || $mysoc->useLocalTax(2)) +{ + if ($mysoc->useLocalTax(1)) + { + $locales = $langs->transcountry("LT1", $mysoc->country_code); + $text ='' . $langs->trans("HideLocalTaxOnPDF", $langs->transcountry("LT1", $mysoc->country_code)) . ''; + $text.= $form->selectyesno('MAIN_PDF_MAIN_HIDE_SECOND_TAX', (!empty($conf->global->MAIN_PDF_MAIN_HIDE_SECOND_TAX)) ? $conf->global->MAIN_PDF_MAIN_HIDE_SECOND_TAX : 0, 1); + $text .= ''; + } + + if ($mysoc->useLocalTax(2)) + { + $locales.=($locales?' & ':'').$langs->transcountry("LT2", $mysoc->country_code); + + $text.= '' . $langs->trans("HideLocalTaxOnPDF", $langs->transcountry("LT2", $mysoc->country_code)) . ''; + $text.= $form->selectyesno('MAIN_PDF_MAIN_HIDE_THIRD_TAX', (!empty($conf->global->MAIN_PDF_MAIN_HIDE_THIRD_TAX)) ? $conf->global->MAIN_PDF_MAIN_HIDE_THIRD_TAX : 0, 1); + $text.= ''; + } +} + +$title = $langs->trans("PDFRulesForSalesTax"); +if ($mysoc->useLocalTax(1) || $mysoc->useLocalTax(2)) +{ + $title.=' - '.$langs->trans("PDFLocaltax", $locales); +} + +print load_fiche_titre($title, '', ''); + +print ''; +print ''; + +// Hide any information on Sale tax / VAT + +print ''; + +// Locataxes +print $text; + +print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("HideAnyVATInformationOnPDF").''; +print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))?$conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT:0, 1); +print '
'; +print '
'; + + +// Other +print load_fiche_titre($langs->trans("Other"), '', ''); + +print '
'; +print ''; +print ''; + +//Desc + +print ''; + +//Ref + +print ''; + +//Details + +print ''; + +//Invert sender and recipient + +print ''; + +// Place customer adress to the ISO location + +print ''; + + +print ''; + +print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("HideDescOnPDF").''; +print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_DESC', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DESC))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DESC:0, 1); +print '
'.$langs->trans("HideRefOnPDF").''; +print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_REF', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_REF))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_REF:0, 1); +print '
'.$langs->trans("HideDetailsOnPDF").''; +print $form->selectyesno('MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS', (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS))?$conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_DETAILS:0, 1); +print '
'.$langs->trans("SwapSenderAndRecipientOnPDF").''; +print $form->selectyesno('MAIN_INVERT_SENDER_RECIPIENT', (! empty($conf->global->MAIN_INVERT_SENDER_RECIPIENT))?$conf->global->MAIN_INVERT_SENDER_RECIPIENT:0, 1); +print '
'.$langs->trans("PlaceCustomerAddressToIsoLocation").''; +print $form->selectyesno('MAIN_PDF_USE_ISO_LOCATION', (! empty($conf->global->MAIN_PDF_USE_ISO_LOCATION))?$conf->global->MAIN_PDF_USE_ISO_LOCATION:0, 1); +print '
'.$langs->trans("ShowDetailsInPDFPageFoot").''; +print $form->selectarray('MAIN_GENERATE_DOCUMENTS_SHOW_FOOT_DETAILS', $arraydetailsforpdffoot, $conf->global->MAIN_GENERATE_DOCUMENTS_SHOW_FOOT_DETAILS); +print '
'; +print '
'; + + +/* + * Library + */ + +print '
'; +print load_fiche_titre($langs->trans("Library"), '', ''); + +print '
'; +print ''."\n"; + +print ''."\n"; +print ''."\n"; +print ''."\n"; +print "\n"; + +print ''."\n"; +print ''."\n"; +print ''."\n"; +print ''."\n"; + +print "
'.$langs->trans("Name").''.$langs->trans("Value").'
'.$langs->trans("LibraryToBuildPDF").''; +$i=0; +$pdf=pdf_getInstance('A4'); +if (class_exists('FPDF') && ! class_exists('TCPDF')) +{ + if ($i) print ' + '; + print 'FPDF'; + print ' ('.@constant('FPDF_PATH').')'; + $i++; +} +if (class_exists('TCPDF')) +{ + if ($i) print ' + '; + print 'TCPDF'; + print ' ('.@constant('TCPDF_PATH').')'; + $i++; +} +if (class_exists('FPDI')) +{ + if ($i) print ' + '; + print 'FPDI'; + print ' ('.@constant('FPDI_PATH').')'; + $i++; +} +if (class_exists('TCPDI')) +{ + if ($i) print ' + '; + print 'TCPDI'; + print ' ('.@constant('TCPDI_PATH').')'; + $i++; +} +print '
\n"; +print '
'; + + +print '
'; +print ''; +print '
'; + +print ''; + + // End of page llxFooter(); $db->close(); diff --git a/htdocs/admin/security_other.php b/htdocs/admin/security_other.php index 28c3db6f1d3..c9bf1ba4357 100644 --- a/htdocs/admin/security_other.php +++ b/htdocs/admin/security_other.php @@ -88,7 +88,7 @@ llxHeader('', $langs->trans("Miscellaneous"), $wikihelp); print load_fiche_titre($langs->trans("SecuritySetup"), '', 'title_setup'); -print $langs->trans("MiscellaneousDesc")."
\n"; +print ''.$langs->trans("MiscellaneousDesc")."
\n"; print "
\n"; diff --git a/htdocs/admin/sms.php b/htdocs/admin/sms.php index e08c2c5eca8..73cad8f69ad 100644 --- a/htdocs/admin/sms.php +++ b/htdocs/admin/sms.php @@ -147,7 +147,7 @@ llxHeader('', $langs->trans("Setup"), $wikihelp); print load_fiche_titre($langs->trans("SmsSetup"), '', 'title_setup'); -print $langs->trans("SmsDesc")."
\n"; +print ''.$langs->trans("SmsDesc")."
\n"; print "
\n"; // List of sending methods diff --git a/htdocs/admin/translation.php b/htdocs/admin/translation.php index ad7a2278991..ba2dde77bec 100644 --- a/htdocs/admin/translation.php +++ b/htdocs/admin/translation.php @@ -229,7 +229,7 @@ print load_fiche_titre($langs->trans("Translation"), $enabledisablehtml, 'title_ $current_language_code=$langs->defaultlang; $s=picto_from_langcode($current_language_code); -print $form->textwithpicto($langs->trans("CurrentUserLanguage").': '.$s.' '.$current_language_code.'', $langs->trans("TranslationDesc")).'
'; +print ''.$form->textwithpicto($langs->trans("CurrentUserLanguage").': '.$s.' '.$current_language_code.'', $langs->trans("TranslationDesc")).'
'; print '
'; diff --git a/htdocs/core/boxes/box_accountancy_suspense_account.php b/htdocs/core/boxes/box_accountancy_suspense_account.php index 9740de82fbc..03c0f0ab7ae 100644 --- a/htdocs/core/boxes/box_accountancy_suspense_account.php +++ b/htdocs/core/boxes/box_accountancy_suspense_account.php @@ -108,14 +108,14 @@ class box_accountancy_suspense_account extends ModeleBoxes ); } else { $this->info_box_contents[0][0] = array( - 'td' => 'class="nohover opacitymedium left"', - 'text' => $langs->trans("SuspenseAccountNotDefined") + 'td' => 'class="nohover"', + 'text' => ''.$langs->trans("SuspenseAccountNotDefined").'' ); } } else { $this->info_box_contents[0][0] = array( - 'td' => 'class="nohover opacitymedium left"', - 'text' => $langs->trans("ReadPermissionNotAllowed") + 'td' => 'class="nohover"', + 'text' => ''.$langs->trans("ReadPermissionNotAllowed").'' ); } } diff --git a/htdocs/core/menus/standard/eldy.lib.php b/htdocs/core/menus/standard/eldy.lib.php index 5d9a637de58..490d033dbf3 100644 --- a/htdocs/core/menus/standard/eldy.lib.php +++ b/htdocs/core/menus/standard/eldy.lib.php @@ -702,8 +702,8 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM $warnpicto = ' '.img_warning($langs->trans("WarningMandatorySetupNotComplete")); } $newmenu->add("/admin/modules.php?mainmenu=home", $langs->trans("Modules").$warnpicto, 1); - $newmenu->add("/admin/menus.php?mainmenu=home", $langs->trans("Menus"), 1); $newmenu->add("/admin/ihm.php?mainmenu=home", $langs->trans("GUISetup"), 1); + $newmenu->add("/admin/menus.php?mainmenu=home", $langs->trans("Menus"), 1); $newmenu->add("/admin/translation.php?mainmenu=home", $langs->trans("Translation"), 1); $newmenu->add("/admin/defaultvalues.php?mainmenu=home", $langs->trans("DefaultValues"), 1);