diff --git a/htdocs/about.php b/htdocs/about.php index aa0d9dddd83..ac684fcd1c0 100644 --- a/htdocs/about.php +++ b/htdocs/about.php @@ -34,7 +34,19 @@ require("./pre.inc.php"); llxHeader(); -print_fiche_titre( "Dolibarr ".DOL_VERSION,''); +print_titre("Dolibarr"); + +print "
\n"; + +print ''; +print ''; +print "\n"; + +print "\n"; +print "\n"; + +print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
".$langs->trans("Version")."".DOL_VERSION."
".$langs->trans("Language")." (LC_ALL)".setlocale(LC_ALL,0)."
'; +print '
'; print '

'; print $langs->trans("Dolibarr est publié sous licence GNU/GPL"); diff --git a/htdocs/admin/system/index.php b/htdocs/admin/system/index.php index cc4c88d2342..4fc4f970d26 100644 --- a/htdocs/admin/system/index.php +++ b/htdocs/admin/system/index.php @@ -45,6 +45,7 @@ print "
\n"; print ''; print "\n"; print "\n"; +print "\n"; print '
Dolibarr
".$langs->trans("Version")."" . DOL_VERSION . "
".$langs->trans("Language")." (LC_ALL)".setlocale(LC_ALL,0)."
'; print "
\n"; @@ -62,6 +63,7 @@ print ''; print "
\n"; +// Serveur web print ''; print "\n"; print "\n"; @@ -71,6 +73,7 @@ print '
".$langs->trans("WebServer")."
".$langs->trans("Version")."".$_SERVER["SERVER_SOFTWARE"]."
'; print "
\n"; +// Php print ''; print "\n"; print "\n"; @@ -79,6 +82,7 @@ print '
".$langs->trans("Php")."
".$langs->trans("Version")."".phpversion()."
'; print "
\n"; +// Base de donnée print ''; print "\n"; diff --git a/htdocs/admin/system/os.php b/htdocs/admin/system/os.php index 6d1cb7a97a2..cf7e2e32db6 100644 --- a/htdocs/admin/system/os.php +++ b/htdocs/admin/system/os.php @@ -44,7 +44,7 @@ print '\n"; +print "\n"; // Récupère la version de l'OS ob_start(); @@ -52,7 +52,7 @@ phpinfo(); $chaine = ob_get_contents(); ob_end_clean(); eregi('System ',$chaine,$reg); -print "\n"; +print "\n"; print '
".$langs->trans("Database")."
'.$langs->trans("Parameter").''.$lan print "\n"; // Récupère l'OS au sens PHP -print "
".$langs->trans("PHP_OS")."".PHP_OS."
".$langs->trans("PHP_OS")."".PHP_OS."
([^\/]*)
".$langs->trans("Version")."".$reg[1]."
".$langs->trans("Version")."".$reg[1]."
'; diff --git a/htdocs/admin/system/web.php b/htdocs/admin/system/web.php index 003515e8660..e3aabf4e939 100644 --- a/htdocs/admin/system/web.php +++ b/htdocs/admin/system/web.php @@ -41,11 +41,12 @@ print "
\n"; print ''; print "\n"; -print "\n"; +print "\n"; print "\n"; -print "\n"; +print "\n"; print "\n"; -print "\n"; +print "\n"; +print "\n"; print '
".$langs->trans("Parameter")."".$langs->trans("Value")."
".$langs->trans("Version")."".$_SERVER["SERVER_SOFTWARE"]."
".$langs->trans("Version")."".$_SERVER["SERVER_SOFTWARE"]."
".$langs->trans("VirtualServerName")."" . $_SERVER["SERVER_NAME"] . "
".$langs->trans("IP")."".$_SERVER["SERVER_ADDR"]."
".$langs->trans("IP")."".$_SERVER["SERVER_ADDR"]."
".$langs->trans("Port")."" . $_SERVER["SERVER_PORT"] . "
".$langs->trans("DocumentRootServer")."".$_SERVER["DOCUMENT_ROOT"]."
".$langs->trans("DocumentRootServer")."".$_SERVER["DOCUMENT_ROOT"]."
".$langs->trans("DataRootServer")."" . DOL_DATA_ROOT . "
'; diff --git a/htdocs/lib/functions.inc.php b/htdocs/lib/functions.inc.php index 4796dbb25a2..1931c6f509b 100644 --- a/htdocs/lib/functions.inc.php +++ b/htdocs/lib/functions.inc.php @@ -312,36 +312,36 @@ function dolibarr_time_plus_duree($time,$duration_value,$duration_unit) /** - \brief Formattage de la date - \param time date timestamp ou au format YYYY-MM-DD - \param format format de la date "%d %b %Y" - \return string date formatée + \brief Formattage de la date en fonction de la langue $conf->langage + \param time date 'timestamp' ou format 'YYYY-MM-DD' ou 'YYYY-MM-DD HH:MM:SS' + \param format format d'affichage de la date "%d %b %Y" + \return string date formatée */ function dolibarr_print_date($time,$format="%d %b %Y") { - // Analyse de la date - if (eregi('^([0-9]+)\-([0-9]+)\-([0-9]+)\s?([0-9]+)?:?([0-9]+)?',$time,$reg)) { - // Date au format 'YYYY-MM-DD' ou 'YYYY-MM-DD HH:MM:SS' - $syear = $reg[1]; - $smonth = $reg[2]; - $sday = $reg[3]; - $shour = $reg[4]; - $smin = $reg[5]; - if ($syear < 1970 && $_SERVER["WINDIR"]) - { - // Le formatage ne peut etre appliqué car windows ne supporte pas la fonction - // mktime si l'année est inférieur à 1970. On retourne un format fixe - return "$syear-$smonth-$sday"; - } - else - { - return strftime($format,mktime($shour,$smin,0,$smonth,$sday,$syear)); - } - } - else { - // Date est un timestamps - return strftime($format,$time); - } + // Analyse de la date + if (eregi('^([0-9]+)\-([0-9]+)\-([0-9]+)\s?([0-9]+)?:?([0-9]+)?',$time,$reg)) { + // Date au format 'YYYY-MM-DD' ou 'YYYY-MM-DD HH:MM:SS' + $syear = $reg[1]; + $smonth = $reg[2]; + $sday = $reg[3]; + $shour = $reg[4]; + $smin = $reg[5]; + if ($syear < 1970 && $_SERVER["WINDIR"]) + { + // Le formatage ne peut etre appliqué car windows ne supporte pas la fonction + // mktime si l'année est inférieur à 1970. On retourne un format fixe + return "$syear-$smonth-$sday"; + } + else + { + return strftime($format,mktime($shour,$smin,0,$smonth,$sday,$syear)); + } + } + else { + // Date est un timestamps + return strftime($format,$time); + } } diff --git a/htdocs/master.inc.php b/htdocs/master.inc.php index f3a05f3a149..1393fd6fc38 100644 --- a/htdocs/master.inc.php +++ b/htdocs/master.inc.php @@ -167,10 +167,13 @@ if (! defined('MAIN_LANG_DEFAULT')) } $conf->langage=MAIN_LANG_DEFAULT; -// On corrige $conf->language si il ne vaut pas le code long: fr_FR par exemple +// On corrige $conf->langage si il ne vaut pas le code long: fr -> fr_FR par exemple if (strlen($conf->langage) <= 3) { $conf->langage = strtolower($conf->langage)."_".strtoupper($conf->langage); } +$conf->langage_tiret=ereg_replace('_','-',$conf->langage); + +setlocale(LC_ALL, $conf->langage_tiret); // Compenser pb de locale avec windows setlocale(LC_ALL, $conf->langage); require_once(DOL_DOCUMENT_ROOT ."/translate.class.php");