From b53d8a68f622d521e6fbc2774e00ca67837d8efb Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 10 May 2009 06:22:21 +0000 Subject: [PATCH] New: Enhance help center --- htdocs/langs/en_US/admin.lang | 2 +- htdocs/langs/en_US/help.lang | 1 + htdocs/langs/fr_FR/help.lang | 5 +++-- htdocs/lib/security.lib.php | 21 +++++++++++++++++++-- 4 files changed, 24 insertions(+), 5 deletions(-) diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang index 5c16d154e10..c69c3e88a6d 100644 --- a/htdocs/langs/en_US/admin.lang +++ b/htdocs/langs/en_US/admin.lang @@ -175,7 +175,7 @@ OfficialWebSiteFr=French official web site OfficialWikiFr=French wiki OfficialWiki=Dolibarr Wiki OfficialDemo=Dolibarr online demo -ForDocumentationSeeWiki=For a user or developer documentation, for FAQs (Frequently Asked Questions), take a lookt at the Dolibarr Wiki: %s +ForDocumentationSeeWiki=For user's or developer's documentation, for FAQs (Frequently Asked Questions), take a look at the Dolibarr Wiki: %s ForAnswersSeeForum=For other questions, help, you can read/ask questions on Dolibarr forum: %s HelpCenterDesc1=This area can help you to get a Help support service on Dolibarr. HelpCenterDesc2=Some part of this service are available in english only. diff --git a/htdocs/langs/en_US/help.lang b/htdocs/langs/en_US/help.lang index 74252fdbc0a..be607f3d917 100644 --- a/htdocs/langs/en_US/help.lang +++ b/htdocs/langs/en_US/help.lang @@ -12,3 +12,4 @@ ToGoBackToDolibarr=To go back on Dolibarr, click here. TypeOfSupport=Nature of support TypeSupportCommunauty=Community (free) TypeSupportCommercial=Commercial +NeedHelpCenter=Need help or support ? diff --git a/htdocs/langs/fr_FR/help.lang b/htdocs/langs/fr_FR/help.lang index b068133661e..83aa16b1184 100644 --- a/htdocs/langs/fr_FR/help.lang +++ b/htdocs/langs/fr_FR/help.lang @@ -6,9 +6,10 @@ RemoteControlSupport=Assistance en ligne temps réel OtherSupport=Autres type d'assistance ToSeeListOfAvailableRessources=Pour contacter/voir les ressources disponibles: ClickHere=Cliquez ici -HelpCenter=Centre d'aide +HelpCenter=Centre d'assistance DolibarrHelpCenter=Centre de support et d'aide Dolibarr ToGoBackToDolibarr=Pour aller sur Dolibarr, cliquer ici. TypeOfSupport=Nature du support -TypeSupportCommunauty=Communitaire (gratuit) +TypeSupportCommunauty=Communautaire (gratuit) TypeSupportCommercial=Commercial +NeedHelpCenter=Besoin d'un support ou aide ? diff --git a/htdocs/lib/security.lib.php b/htdocs/lib/security.lib.php index 6647108cd11..701c2df0982 100644 --- a/htdocs/lib/security.lib.php +++ b/htdocs/lib/security.lib.php @@ -181,9 +181,26 @@ function dol_loginfunction($langs,$conf,$mysoc) print ''; print ''; - if (empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK)) + if (empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK) || empty($conf->global->MAIN_HELPCENTER_DISABLELINK)) { - print '('.$langs->trans("PasswordForgotten").')'; + print ''; + if (empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK)) + { + print '('; + print $langs->trans("PasswordForgotten"); + if (! empty($conf->global->MAIN_HELPCENTER_DISABLELINK)) print ')'; + } + + if (empty($conf->global->MAIN_HELPCENTER_DISABLELINK)) + { + $langs->load("help"); + print ''; + if (! empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK)) print '('; + else print ' - '; + print $langs->trans("NeedHelpCenter"); + } + print ')'; + print ''; } print ''."\n";