Some fix into perf.php page.

This commit is contained in:
Laurent Destailleur 2013-07-24 00:34:08 +02:00
parent 74ce3fe738
commit 68d83dd653
3 changed files with 24 additions and 18 deletions

View File

@ -56,10 +56,10 @@ print '<br>';
print '<strong>'.$langs->trans("XDebug").'</strong>: '; print '<strong>'.$langs->trans("XDebug").'</strong>: ';
$test=!function_exists('xdebug_is_enabled'); $test=!function_exists('xdebug_is_enabled');
if ($test) print img_picto('','tick.png').' '.$langs->trans("NotInstalled"); if ($test) print img_picto('','tick.png').' '.$langs->trans("NotInstalled");
else else
{ {
print img_picto('','warning').' '.$langs->trans("XDebugInstalled"); print img_picto('','warning').' '.$langs->trans("XDebugInstalled");
print $langs->trans("MoreInformation").' <a href="'.DOL_URL_ROOT.'/admin/xdebug.php'.'">XDebug admin page</a>'; print ' '.$langs->trans("MoreInformation").' <a href="'.DOL_URL_ROOT.'/admin/system/xdebug.php'.'">XDebug admin page</a>';
} }
print '<br>'; print '<br>';
@ -67,12 +67,12 @@ print '<br>';
print '<br>'; print '<br>';
print '<strong>'.$langs->trans("ApplicativeCache").'</strong>: '; print '<strong>'.$langs->trans("ApplicativeCache").'</strong>: ';
$test=!empty($conf->memcached->enabled); $test=!empty($conf->memcached->enabled);
if ($test) if ($test)
{ {
if (!empty($conf->global->MEMCACHED_SERVER)) if (!empty($conf->global->MEMCACHED_SERVER))
{ {
print img_picto('','tick.png').' '.$langs->trans("MemcachedAvailableAndSetup"); print img_picto('','tick.png').' '.$langs->trans("MemcachedAvailableAndSetup");
print $langs->trans("MoreInformation").' <a href="'.dol_buildpath('/memcached/admin/memcached.php',1).'">Memcached module admin page</a>'; print ' '.$langs->trans("MoreInformation").' <a href="'.dol_buildpath('/memcached/admin/memcached.php',1).'">Memcached module admin page</a>';
} }
else else
{ {
@ -86,12 +86,12 @@ print '</br>';
print '<br>'; print '<br>';
print '<strong>'.$langs->trans("OPCodeCache").'</strong>: '; print '<strong>'.$langs->trans("OPCodeCache").'</strong>: ';
$test1=function_exists('xcache_info'); $test1=function_exists('xcache_info');
if ($test1) if ($test1)
{ {
print img_picto('','tick.png').' '.$langs->trans("XCacheInstalled"); print img_picto('','tick.png').' '.$langs->trans("XCacheInstalled");
print $langs->trans("MoreInformation").' <a href="'.DOL_URL_ROOT.'/admin/xcache.php'.'">Xcache admin page</a>'; print ' '.$langs->trans("MoreInformation").' <a href="'.DOL_URL_ROOT.'/admin/xcache.php'.'">Xcache admin page</a>';
} }
else else
{ {
$test2=function_exists('eaccelerator_info'); $test2=function_exists('eaccelerator_info');
if ($test2) print img_picto('','tick.png').' '.$langs->trans("EAcceleratorInstalled"); if ($test2) print img_picto('','tick.png').' '.$langs->trans("EAcceleratorInstalled");
@ -140,7 +140,7 @@ jQuery(document).ready(function() {
} }
} }
}) })
var getcssurl; var getcssurl;
var cachecssstring; var cachecssstring;
var compcssstring; var compcssstring;
@ -181,7 +181,7 @@ jQuery(document).ready(function() {
}) })
var getcssphpurl; var getcssphpurl;
var cachecssphpstring; var cachecssphpstring;
var compcssphpstring; var compcssphpstring;
getcssphpurl = $.ajax({ getcssphpurl = $.ajax({
type: "GET", type: "GET",
@ -218,7 +218,7 @@ jQuery(document).ready(function() {
} }
} }
}) })
var getimgurl; var getimgurl;
var cacheimgstring; var cacheimgstring;
var compimgstring; var compimgstring;
@ -254,7 +254,7 @@ jQuery(document).ready(function() {
{ {
jQuery("#httpcompimgok").show(); jQuery("#httpcompimgok").show();
jQuery("#httpcompimgko").hide(); jQuery("#httpcompimgko").hide();
} }
} }
}) })
@ -293,7 +293,7 @@ jQuery(document).ready(function() {
{ {
jQuery("#httpcompjsok").show(); jQuery("#httpcompjsok").show();
jQuery("#httpcompjsko").hide(); jQuery("#httpcompjsko").hide();
} }
} }
}) })
@ -332,7 +332,7 @@ jQuery(document).ready(function() {
{ {
jQuery("#httpcompjsphpok").show(); jQuery("#httpcompjsphpok").show();
jQuery("#httpcompjsphpko").hide(); jQuery("#httpcompjsphpko").hide();
} }
} }
}) })
@ -413,20 +413,22 @@ if ($resql)
{ {
$limitforoptim=10000; $limitforoptim=10000;
$num=$db->num_rows($resql); $num=$db->num_rows($resql);
$obj=$db->fetch_object($resql);
$nb=$obj->nb;
if ($nb > $limitforoptim) if ($nb > $limitforoptim)
{ {
if (empty($conf->global->PRODUCT_DONOTSEARCH_ANYWHERE)) if (empty($conf->global->PRODUCT_DONOTSEARCH_ANYWHERE))
{ {
print img_picto('','warning.png').' '.$langs->trans("YouHaveXProductUseSearchOptim",$num); print img_picto('','warning.png').' '.$langs->trans("YouHaveXProductUseSearchOptim",$nb);
} }
else else
{ {
print img_picto('','tick.png').' '.$langs->trans("YouHaveXProductAndSearchOptimOn",$num); print img_picto('','tick.png').' '.$langs->trans("YouHaveXProductAndSearchOptimOn",$nb);
} }
} }
else else
{ {
print img_picto('','tick.png').' '.$langs->trans("NbOfProductIsLowerThanNoPb",$limitforoptim); print img_picto('','tick.png').' '.$langs->trans("NbOfProductIsLowerThanNoPb",$nb);
} }
print '<br>'; print '<br>';
$db->free($resql); $db->free($resql);
@ -437,7 +439,7 @@ print '<br>';
print '<strong>'.$langs->trans("Browser").'</strong>:<br>'; print '<strong>'.$langs->trans("Browser").'</strong>:<br>';
if (! in_array($conf->browser->name, array('chrome','opera','safari','firefox'))) if (! in_array($conf->browser->name, array('chrome','opera','safari','firefox')))
{ {
print img_picto('','warning.png').' '.$langs->trans("BrowserIsKO",$conf->browser->name); print img_picto('','warning.png').' '.$langs->trans("BrowserIsKO",$conf->browser->name);
} }
else else
{ {

View File

@ -990,6 +990,8 @@ SearchOptim=Search optimization
YouHaveXProductUseSearchOptim=You have %s product into database. You should add the constant PRODUCT_DONOTSEARCH_ANYWHERE to 1 into Home-Setup-Other, you limit the search to the beginning of strings making possible for database to use index and you should get an immediate response. YouHaveXProductUseSearchOptim=You have %s product into database. You should add the constant PRODUCT_DONOTSEARCH_ANYWHERE to 1 into Home-Setup-Other, you limit the search to the beginning of strings making possible for database to use index and you should get an immediate response.
BrowserIsOK=You are using the web browser %s. This browser is ok for security and performance. BrowserIsOK=You are using the web browser %s. This browser is ok for security and performance.
BrowserIsKO=You are using the web browser %s. This browser is known to be a bad choice for security, performance and reliability. We recommand you to use Firefox, Chrome, Opera or Safari. BrowserIsKO=You are using the web browser %s. This browser is known to be a bad choice for security, performance and reliability. We recommand you to use Firefox, Chrome, Opera or Safari.
XDebugInstalled=XDebug est chargé.
XCacheInstalled=XCache is loaded.
##### Module password generation ##### Module password generation
PasswordGenerationStandard=Return a password generated according to internal Dolibarr algorithm: 8 characters containing shared numbers and characters in lowercase. PasswordGenerationStandard=Return a password generated according to internal Dolibarr algorithm: 8 characters containing shared numbers and characters in lowercase.
PasswordGenerationNone=Do not suggest any generated password. Password must be type in manually. PasswordGenerationNone=Do not suggest any generated password. Password must be type in manually.

View File

@ -1006,6 +1006,8 @@ SearchOptim=Optimization des recherches
YouHaveXProductUseSearchOptim=Vous avez %s produits/services en base. Il est recommandé d'ajouter la constante PRODUCT_DONOTSEARCH_ANYWHERE à 1 dans Accueil-Configuration-Divers, vous limiterez ainsi la recherche au début de la chaine rendant possible l'utilisation de l'index et obtiendrez une réponse immédiate. YouHaveXProductUseSearchOptim=Vous avez %s produits/services en base. Il est recommandé d'ajouter la constante PRODUCT_DONOTSEARCH_ANYWHERE à 1 dans Accueil-Configuration-Divers, vous limiterez ainsi la recherche au début de la chaine rendant possible l'utilisation de l'index et obtiendrez une réponse immédiate.
BrowserIsOK=Vous utilisez le navigateur %s. Ce navigateur est réputé optimisé pour la sécurité et performance. BrowserIsOK=Vous utilisez le navigateur %s. Ce navigateur est réputé optimisé pour la sécurité et performance.
BrowserIsKO=Vous utilisez le navigateur %s. Ce navigateur est déconseillé pour des raisons de sécurité, performance et qualité des pages restituées. Nous vous recommandons d'utiliser Firefox, Chrome, Opera ou Safari. BrowserIsKO=Vous utilisez le navigateur %s. Ce navigateur est déconseillé pour des raisons de sécurité, performance et qualité des pages restituées. Nous vous recommandons d'utiliser Firefox, Chrome, Opera ou Safari.
XDebugInstalled=XDebug est chargé.
XCacheInstalled=XCache est chargé.
##### Module password generation ##### Module password generation
PasswordGenerationStandard=Renvoie un mot de passe généré selon l'algorithme interne de Dolibarr : 8 caractères, chiffres et caractères en minuscules mélangés. PasswordGenerationStandard=Renvoie un mot de passe généré selon l'algorithme interne de Dolibarr : 8 caractères, chiffres et caractères en minuscules mélangés.
PasswordGenerationNone=Ne propose pas de mots de passe générés. Le mot de passe est à saisir manuellement. PasswordGenerationNone=Ne propose pas de mots de passe générés. Le mot de passe est à saisir manuellement.