diff --git a/htdocs/admin/agenda_extsites.php b/htdocs/admin/agenda_extsites.php index f0187da6881781c2831fb12973e6e59b14d39970..c1a9ec3afd2d4736ea65b2cf06b2a1d6a8f91458 100644 --- a/htdocs/admin/agenda_extsites.php +++ b/htdocs/admin/agenda_extsites.php @@ -1,6 +1,6 @@ <?php -/* Copyright (C) 2008-2011 Laurent Destailleur <eldy@users.sourceforge.net> - * Copyright (C) 2011-2014 Juanjo Menent <jmenent@2byte.es> +/* Copyright (C) 2008-2011 Laurent Destailleur <eldy@users.sourceforge.net> + * Copyright (C) 2011-2015 Juanjo Menent <jmenent@2byte.es> * Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr> * * This program is free software; you can redistribute it and/or modify @@ -158,7 +158,7 @@ if ($conf->use_javascript_ajax) } else { - if($conf->global->AGENDA_DISABLE_EXT == 0) + if (empty($conf->global->AGENDA_DISABLE_EXT)) { print '<a href="'.$_SERVER['PHP_SELF'].'?save=1&AGENDA_DISABLE_EXT=1">'.img_picto($langs->trans("Enabled"),'on').'</a>'; } diff --git a/htdocs/admin/confexped.php b/htdocs/admin/confexped.php index 273f4405f9a3d7d91c78fbfbd74ff13a458f18db..a6ed0acae30cb7bdf952068cf41af6e8446ef793 100644 --- a/htdocs/admin/confexped.php +++ b/htdocs/admin/confexped.php @@ -2,7 +2,7 @@ /* Copyright (C) 2004-2010 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com> * Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr> - * Copyright (C) 2011 Juanjo Menent <jmenent@2byte.es> + * Copyright (C) 2011-2015 Juanjo Menent <jmenent@2byte.es> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -121,11 +121,11 @@ print '<td align="center" width="20">'; print '</td>'; print '<td align="center" width="100">'; -if($conf->global->MAIN_SUBMODULE_EXPEDITION == 0) +if (empty($conf->global->MAIN_SUBMODULE_EXPEDITION)) { print '<a href="confexped.php?action=activate_sending">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>'; } -else if($conf->global->MAIN_SUBMODULE_EXPEDITION == 1) +else { print '<a href="confexped.php?action=disable_sending">'.img_picto($langs->trans("Enabled"),'switch_on').'</a>'; } @@ -141,11 +141,11 @@ print '<td align="center" width="20">'; print '</td>'; print '<td align="center" width="100">'; -if($conf->global->MAIN_SUBMODULE_LIVRAISON == 0) +if (empty($conf->global->MAIN_SUBMODULE_LIVRAISON)) { print '<a href="confexped.php?action=activate_delivery">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>'; } -else if($conf->global->MAIN_SUBMODULE_LIVRAISON == 1) +else { print '<a href="confexped.php?action=disable_delivery">'.img_picto($langs->trans("Enabled"),'switch_on').'</a>'; } diff --git a/htdocs/admin/ecm.php b/htdocs/admin/ecm.php index 2f107a558b5d778b507141119a3f27c1388ae97b..ed75fd141f9596621da79d460b5983954ac7363b 100644 --- a/htdocs/admin/ecm.php +++ b/htdocs/admin/ecm.php @@ -1,5 +1,6 @@ <?php /* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro> + * Copyright (C) 2015 Juanjo Menent <jmenent@2byte.es> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -95,11 +96,11 @@ if ($conf->use_javascript_ajax) } else { - if($conf->global->ECM_AUTO_TREE_ENABLED == 0) + if (empty($conf->global->ECM_AUTO_TREE_ENABLED)) { print '<a href="'.$_SERVER['PHP_SELF'].'?action=set_ECM_AUTO_TREE_ENABLED">'.img_picto($langs->trans("Disabled"),'off').'</a>'; } - else if($conf->global->USER_MAIL_REQUIRED == 1) + else if(! empty($conf->global->USER_MAIL_REQUIRED)) { print '<a href="'.$_SERVER['PHP_SELF'].'?action=del_ECM_AUTO_TREE_ENABLED">'.img_picto($langs->trans("Enabled"),'on').'</a>'; } diff --git a/htdocs/admin/pdf.php b/htdocs/admin/pdf.php index d635b64803ad7ddf3d95db923a65bfa9fa7e192c..9f12c98e1d8f69e592a21aed8fff1fc927d9b48e 100644 --- a/htdocs/admin/pdf.php +++ b/htdocs/admin/pdf.php @@ -2,7 +2,7 @@ /* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org> * Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com> - * Copyright (C) 2012-2103 Juanjo Menent <jmenent@2byte.es> + * Copyright (C) 2012-2105 Juanjo Menent <jmenent@2byte.es> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -408,11 +408,11 @@ else // Show } print '</td>'; print '<td align="center" width="140">'; - if ($conf->global->PDF_SECURITY_ENCRYPTION == 0) + if (empty($conf->global->PDF_SECURITY_ENCRYPTION)) { print '<a href="'.$_SERVER["PHP_SELF"].'?action=activate_pdfsecurity">'.$langs->trans("Activate").'</a>'; } - if($conf->global->PDF_SECURITY_ENCRYPTION == 1) + else { print '<a href="'.$_SERVER["PHP_SELF"].'?action=disable_pdfsecurity">'.$langs->trans("Disable").'</a>'; } diff --git a/htdocs/admin/security.php b/htdocs/admin/security.php index 9be7f09aa0e75ae24e2ef560596f3df109114aa6..0eeef2cbe15899ea03098bfb755271ed832d8acd 100644 --- a/htdocs/admin/security.php +++ b/htdocs/admin/security.php @@ -1,7 +1,7 @@ <?php /* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2005-2007 Regis Houssin <regis.houssin@capnetworks.com> - * Copyright (C) 2013 Juanjo Menent <jmenent@2byte.es> + * Copyright (C) 2013-2015 Juanjo Menent <jmenent@2byte.es> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -470,18 +470,18 @@ $var=!$var; print "<tr ".$bc[$var].">"; print '<td colspan="3">'.$langs->trans("DisableForgetPasswordLinkOnLogonPage").'</td>'; print '<td align="center" width="60">'; -if($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK == 1) +if(! empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK)) { print img_picto($langs->trans("Active"),'tick'); } print '</td>'; -if ($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK == 0) +if (empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK)) { print '<td align="center" width="100">'; print '<a href="security.php?action=activate_MAIN_SECURITY_DISABLEFORGETPASSLINK">'.$langs->trans("Activate").'</a>'; print "</td>"; } -if($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK == 1) +if (!empty($conf->global->MAIN_SECURITY_DISABLEFORGETPASSLINK)) { print '<td align="center" width="100">'; print '<a href="security.php?action=disable_MAIN_SECURITY_DISABLEFORGETPASSLINK">'.$langs->trans("Disable").'</a>'; diff --git a/htdocs/admin/user.php b/htdocs/admin/user.php index d7cfe2c790ee67fe68c01c8a71a28bd162e08bb2..dc21790ec32dc8df16f4c6f3185e7af0c7708e7e 100644 --- a/htdocs/admin/user.php +++ b/htdocs/admin/user.php @@ -1,10 +1,11 @@ <?php -/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org> - * Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org> - * Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net> - * Copyright (C) 2004 Sebastien Di Cintio <sdicintio@ressource-toi.org> - * Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be> - * Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com> +/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org> + * Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org> + * Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net> + * Copyright (C) 2004 Sebastien Di Cintio <sdicintio@ressource-toi.org> + * Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be> + * Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com> + * Copyright (C) 2015 Juanjo Menent <jmenent@2byte.es> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -124,11 +125,11 @@ if ($conf->use_javascript_ajax) } else { - if($conf->global->USER_MAIL_REQUIRED == 0) + if (empty($conf->global->USER_MAIL_REQUIRED)) { print '<a href="'.$_SERVER['PHP_SELF'].'?action=set_USER_MAIL_REQUIRED">'.img_picto($langs->trans("Disabled"),'off').'</a>'; } - else if($conf->global->USER_MAIL_REQUIRED == 1) + else { print '<a href="'.$_SERVER['PHP_SELF'].'?action=del_USER_MAIL_REQUIRED">'.img_picto($langs->trans("Enabled"),'on').'</a>'; }