diff --git a/htdocs/langs/en_US/main.lang b/htdocs/langs/en_US/main.lang
index 7c66ebe8377..44ec15bff23 100644
--- a/htdocs/langs/en_US/main.lang
+++ b/htdocs/langs/en_US/main.lang
@@ -527,6 +527,7 @@ PDFMerge=PDF Merge
Merge=Merge
PrintContentArea=Show page to print main content area
NoMenu=No sub-menu
+WarningYouAreInMaintenanceMode=Warning, you are in a maintenance mode, so only login %s is allowed to connect.
# Week day
Day1=Monday
Day2=Tuesday
diff --git a/htdocs/langs/fr_FR/main.lang b/htdocs/langs/fr_FR/main.lang
index 86b0ed0aed5..8421b0e3aa9 100644
--- a/htdocs/langs/fr_FR/main.lang
+++ b/htdocs/langs/fr_FR/main.lang
@@ -526,6 +526,7 @@ PDFMerge=Fusion PDF
Merge=Fusion
PrintContentArea=Afficher page d'impression de la zone centrale
NoMenu=Aucun sous-menu
+WarningYouAreInMaintenanceMode=Attention, vous êtes en mode maintenance, aussi seul le login %s est autorisé à se connecter.
# Week day
Day1=Lundi
Day2=Mardi
diff --git a/htdocs/theme/auguria/auguria.css.php b/htdocs/theme/auguria/auguria.css.php
index 17359349426..8fccf2cd3e4 100644
--- a/htdocs/theme/auguria/auguria.css.php
+++ b/htdocs/theme/auguria/auguria.css.php
@@ -23,6 +23,14 @@
* \version $Id$
*/
+if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // We need to use translation files to know direction
+if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
+
//require_once("../../conf/conf.php");
require_once("../../master.inc.php");
diff --git a/htdocs/theme/bluelagoon/bluelagoon.css.php b/htdocs/theme/bluelagoon/bluelagoon.css.php
index 336d456af1d..facd563e1f2 100644
--- a/htdocs/theme/bluelagoon/bluelagoon.css.php
+++ b/htdocs/theme/bluelagoon/bluelagoon.css.php
@@ -24,6 +24,14 @@
* \version $Id$
*/
+if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // We need to use translation files to know direction
+if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
+
//require_once("../../conf/conf.php");
require_once("../../master.inc.php");
diff --git a/htdocs/theme/eldy/eldy.css.php b/htdocs/theme/eldy/eldy.css.php
index 31eb7613c1c..1147c8aa16f 100644
--- a/htdocs/theme/eldy/eldy.css.php
+++ b/htdocs/theme/eldy/eldy.css.php
@@ -24,6 +24,14 @@
* \version $Id$
*/
+if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // We need to use translation files to know direction
+if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
+
//require_once("../../conf/conf.php");
require_once("../../master.inc.php");
diff --git a/htdocs/theme/freelug/freelug.css.php b/htdocs/theme/freelug/freelug.css.php
index 53eba27d382..01bccedb5ba 100644
--- a/htdocs/theme/freelug/freelug.css.php
+++ b/htdocs/theme/freelug/freelug.css.php
@@ -23,6 +23,14 @@
* \version $Id$
*/
+if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // We need to use translation files to know direction
+if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
+
//require_once("../../conf/conf.php");
require_once("../../master.inc.php");
diff --git a/htdocs/theme/rodolphe/rodolphe.css.php b/htdocs/theme/rodolphe/rodolphe.css.php
index a7d39d8de22..82d3737af52 100644
--- a/htdocs/theme/rodolphe/rodolphe.css.php
+++ b/htdocs/theme/rodolphe/rodolphe.css.php
@@ -24,6 +24,14 @@
* \version $Id$
*/
+if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // We need to use translation files to know direction
+if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
+
//require_once("../../conf/conf.php");
require_once("../../master.inc.php");
diff --git a/htdocs/theme/yellow/yellow.css.php b/htdocs/theme/yellow/yellow.css.php
index 88cef2ab743..62f183eca50 100644
--- a/htdocs/theme/yellow/yellow.css.php
+++ b/htdocs/theme/yellow/yellow.css.php
@@ -23,6 +23,14 @@
* \version $Id$
*/
+if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // We need to use translation files to know direction
+if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
+
//require_once("../../conf/conf.php");
require_once("../../master.inc.php");
diff --git a/htdocs/user/logout.php b/htdocs/user/logout.php
index cef76d3332d..eb9766beba4 100644
--- a/htdocs/user/logout.php
+++ b/htdocs/user/logout.php
@@ -25,8 +25,16 @@
* \version $Id$
*/
+//if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Uncomment creates pb to relogon after a disconnect
+if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
+if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
+if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
+if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
+if (! defined('EVEN_IF_ONLY_LOGIN_ALLOWED')) define('EVEN_IF_ONLY_LOGIN_ALLOWED','1');
+
require_once("../main.inc.php");
+// This can happen only with a bookmark or forged url call.
if (!empty($_SESSION["dol_authmode"]) && ($_SESSION["dol_authmode"] == 'forceuser'
|| $_SESSION["dol_authmode"] == 'http'))
{
@@ -36,7 +44,7 @@ if (!empty($_SESSION["dol_authmode"]) && ($_SESSION["dol_authmode"] == 'forceuse
// Define url to go after disconnect
$urlfrom=empty($_SESSION["urlfrom"])?'':$_SESSION["urlfrom"];
-// Phenix module
+// Destroy some cookies
if ($conf->phenix->enabled && $conf->phenix->cookie)
{
// Destroy cookie
@@ -61,6 +69,6 @@ if ($urlfrom)
{
$url=DOL_URL_ROOT.$urlfrom;
}
-
+//print 'url='.$url;exit;
header("Location: ".$url);
?>
diff --git a/scripts/emailings/mailing-send.php b/scripts/emailings/mailing-send.php
index 483c4e4195f..8453a1ded43 100644
--- a/scripts/emailings/mailing-send.php
+++ b/scripts/emailings/mailing-send.php
@@ -1,7 +1,7 @@
#!/usr/bin/php
- * Copyright (C) 2005 Laurent Destailleur
+/* Copyright (C) 2004 Rodolphe Quiedeville
+ * Copyright (C) 2005-2009 Laurent Destailleur
*
* 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
@@ -16,22 +16,6 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- *
- * !!! Envoi mailing !!!
- *
- * L'utilisation d'adresses de courriers �lectroniques dans les op�rations
- * de prospection commerciale est subordonn�e au recueil du consentement
- * pr�alable des personnes concern�es.
- *
- * Le dispositif juridique applicable a �t� introduit par l'article 22 de
- * la loi du 21 juin 2004 pour la confiance dans l'�conomie num�rique.
- *
- * Les dispositions applicables sont d�finies par les articles L. 34-5 du
- * code des postes et des t�l�communications et L. 121-20-5 du code de la
- * consommation. L'application du principe du consentement pr�alable en
- * droit fran�ais r�sulte de la transposition de l'article 13 de la Directive
- * europ�enne du 12 juillet 2002 � Vie priv�e et communications �lectroniques �.
*/