From 5a0a1828b66580405a1fcec772aa03ce11954b2e Mon Sep 17 00:00:00 2001 From: Andre Cianfarani Date: Wed, 1 Mar 2006 12:18:07 +0000 Subject: [PATCH] modif pour date en popup --- htdocs/html.form.class.php | 3 ++- htdocs/lib/lib_calendar.js | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/htdocs/html.form.class.php b/htdocs/html.form.class.php index 33fbbb91508..6490f2bd4b9 100644 --- a/htdocs/html.form.class.php +++ b/htdocs/html.form.class.php @@ -1664,13 +1664,14 @@ class Form */ if ($conf->use_javascript && $conf->use_popup_date) { - print ''; + if ($langs->defaultlang != "") { print ''; } + print ''; $timearray=getDate($set_time); $formated_date=dolibarr_print_date($set_time,$conf->format_date_short); print ' '; diff --git a/htdocs/lib/lib_calendar.js b/htdocs/lib/lib_calendar.js index 1786d128d43..4a607af923e 100755 --- a/htdocs/lib/lib_calendar.js +++ b/htdocs/lib/lib_calendar.js @@ -127,8 +127,8 @@ else { // GET CURRENTLY SELECTED LANGUAGE // selectedLanguage = navigator.language; -selectedLanguage = "en"; - +if(selectedLanguage == "") + selectedLanguage = navigator.language; // PRE-BUILD PORTIONS OF THE CALENDAR WHEN THIS JS LIBRARY LOADS INTO THE BROWSER buildCalParts();