Index: /extensions/NBC_UserAdvManager/trunk/ConfirmMail.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/ConfirmMail.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/ConfirmMail.php	(revision 5056)
@@ -4,5 +4,5 @@
 include_once( PHPWG_ROOT_PATH.'include/common.inc.php' );
 include_once (NBC_UAM_PATH.'include/constants.php');
-include_once (NBC_UAM_PATH.'include/functions_UserAdvManager.inc.php');
+include_once (NBC_UAM_PATH.'include/functions.inc.php');
 
 // +-----------------------------------------------------------------------+
@@ -48,5 +48,4 @@
   '/theme/'.$user['theme'].'/themeconf.inc.php');
 
-/* $template->set_filenames(array('confirm_mail' => realpath(NBC_UAM_PATH . 'ConfirmMail.tpl')));*/
 $template->set_filenames(
   array(
@@ -54,5 +53,5 @@
 	)
 );
-if ( isset($lang['Theme: '.$user['theme']]) )
+if (isset($lang['Theme: '.$user['theme']]))
 {
   $template->assign(
Index: /extensions/NBC_UserAdvManager/trunk/admin/UAM_admin.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/admin/UAM_admin.php	(revision 5056)
+++ /extensions/NBC_UserAdvManager/trunk/admin/UAM_admin.php	(revision 5056)
@@ -0,0 +1,1594 @@
+<?php
+
+global $user, $lang, $conf, $errors;
+
+if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
+// +-----------------------------------------------------------------------+
+// | Check Access and exit when user status is not ok                      |
+// +-----------------------------------------------------------------------+
+check_status(ACCESS_ADMINISTRATOR);
+
+if (!defined('NBC_UAM_PATH')) define('NBC_UAM_PATH' , PHPWG_PLUGINS_PATH.basename(dirname(__FILE__)).'/');
+
+//ini_set('error_reporting', E_ALL);
+//ini_set('display_errors', true);
+
+include_once (PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php');
+include_once (PHPWG_ROOT_PATH.'/include/constants.php');
+$my_base_url = get_admin_plugin_menu_link(__FILE__);
+
+load_language('plugin.lang', NBC_UAM_PATH);
+load_language('help/plugin.lang', NBC_UAM_PATH);
+
+$page['global'] = array();
+$error = array();
+$pattern = '/;/';
+$replacement = '.';
+
+$UAM_Password_Test_Score = 0;
+$UAM_MailInfo_Error_Txt = false;
+$UAM_ConfirmMail_Error_Txt = false;
+$UAM_Reminder_Error_Txt = false;
+$UAM_ConfirmMail_Error_Txt1 = false;
+$UAM_ConfirmMail_Error_Txt2 = false;
+$UAM_Exclusionlist_Error = false;
+
+
+// +-----------------------------------------------------------------------+
+// |                            Tabssheet                                  |
+// +-----------------------------------------------------------------------+
+if (!isset($_GET['tab']))
+	$page['tab'] = 'global';
+else
+  $page['tab'] = $_GET['tab'];
+
+$tabsheet = new tabsheet();
+$tabsheet->add('global',
+               l10n('Tab_Global'),
+               $my_base_url.'&amp;tab=global');
+  $tabsheet->add('userlist',
+                 l10n('Tab_UserList'),
+                 $my_base_url.'&amp;tab=userlist');
+$tabsheet->add('usermanager',
+               l10n('Tab_UserManager'),
+               $my_base_url.'&amp;tab=usermanager');
+$tabsheet->add('ghosttracker',
+               l10n('Tab_GhostTracker'),
+               $my_base_url.'&amp;tab=ghosttracker');
+$tabsheet->select($page['tab']);
+$tabsheet->assign();
+
+
+// +-----------------------------------------------------------------------+
+// |                      Getting plugin version                           |
+// +-----------------------------------------------------------------------+
+$plugin =  PluginVer(NBC_UAM_PATH);
+$version = $plugin['version'] ;
+
+
+// +----------------------------------------------------------+
+// |            FCK Editor for email text fields              |
+// +----------------------------------------------------------+
+
+/* Standby because this may cause too many problems with (;) in text fields */
+//$toolbar = 'Basic';
+//$width = '750px';
+//$height = '300px';
+//$areas = array();
+//array_push( $areas,'UAM_MailInfo_Text','UAM_ConfirmMail_Text','UAM_GhostTracker_ReminderText','UAM_ConfirmMail_ReMail_Txt1','UAM_ConfirmMail_ReMail_Txt2');
+ 
+//if (function_exists('set_fckeditor_instance'))
+//  set_fckeditor_instance($areas, $toolbar, $width, $height);
+
+
+// +-----------------------------------------------------------------------+
+// |                            Tabssheet select                           |
+// +-----------------------------------------------------------------------+
+
+switch ($page['tab'])
+{
+// *************************************************************************
+// +-----------------------------------------------------------------------+
+// |                           Global Config                               |
+// +-----------------------------------------------------------------------+
+// *************************************************************************
+  case 'global':
+
+	if (isset($_POST['submit']) and !is_adviser() and isset($_POST['UAM_Mail_Info']) and isset($_POST['UAM_No_Casse']) and isset($_POST['UAM_Username_Char']) and isset($_POST['UAM_Confirm_Mail']) and isset($_POST['UAM_No_Comment_Anonymous']) and isset($_POST['UAM_Password_Enforced']) and isset($_POST['UAM_AdminPassword_Enforced']) and isset($_POST['UAM_GhostUser_Tracker']))
+  {
+
+/* General configuration settings */
+		$_POST['UAM_MailInfo_Text'] = str_replace("\'", "'", str_replace("\\\\", "\\", $_POST['UAM_MailInfo_Text']));
+    
+		$_POST['UAM_ConfirmMail_Text'] = str_replace("\'", "'", str_replace("\\\\", "\\", $_POST['UAM_ConfirmMail_Text']));
+
+    $_POST['UAM_GhostTracker_ReminderText'] = str_replace("\'", "'", str_replace("\\\\", "\\", $_POST['UAM_GhostTracker_ReminderText']));
+
+
+/* Control of semicolons - Replaced by dots - Warning message is displayed */    
+    if ((preg_match($pattern, $_POST['UAM_MailInfo_Text'])) or (preg_match($pattern, $_POST['UAM_GhostTracker_ReminderText'])) or (preg_match($pattern, $_POST['UAM_ConfirmMail_Text'])))
+    {
+      if (preg_match($pattern, $_POST['UAM_MailInfo_Text']))
+      {
+        $_POST['UAM_MailInfo_Text'] = preg_replace($pattern, $replacement, $_POST['UAM_MailInfo_Text']);
+        $UAM_MailInfo_Error_Txt = true;
+      }
+      
+      if (preg_match($pattern, $_POST['UAM_ConfirmMail_Text']))
+      {
+        $_POST['UAM_ConfirmMail_Text'] = preg_replace($pattern, $replacement, $_POST['UAM_ConfirmMail_Text']);
+        $UAM_ConfirmMail_Error_Txt = true;
+      }
+      
+      if (preg_match($pattern, $_POST['UAM_GhostTracker_ReminderText']))
+      {
+        $_POST['UAM_GhostTracker_ReminderText'] = preg_replace($pattern, $replacement, $_POST['UAM_GhostTracker_ReminderText']);
+        $UAM_Reminder_Error_Txt = true;
+      }
+      
+      array_push($page['errors'], l10n('mail_text_error'));
+    }
+
+    /* Check if CR-LF exist at begining and end of mail exclusion list - If yes, removes them */
+    if (preg_match('/^[\s]+/', $_POST['UAM_MailExclusion_List']))
+    {
+      array_push($page['errors'], l10n('mail_exclusionlist_error'));
+      $UAM_Exclusionlist_Error = true;
+    }
+		
+		$newconf_UAM = array(
+      $_POST['UAM_Mail_Info'],
+      $_POST['UAM_No_Casse'],
+      $_POST['UAM_Confirm_Mail'],
+      (isset($_POST['UAM_No_Confirm_Group'])?$_POST['UAM_No_Confirm_Group']:''),
+      (isset($_POST['UAM_Validated_Group'])?$_POST['UAM_Validated_Group']:''),
+      (isset($_POST['UAM_Validated_Status'])?$_POST['UAM_Validated_Status']:''),
+      $_POST['UAM_No_Comment_Anonymous'],
+      $_POST['UAM_Username_Char'],
+      $_POST['UAM_Username_List'],
+      (isset($_POST['UAM_No_Confirm_Status'])?$_POST['UAM_No_Confirm_Status']:''),
+      $_POST['UAM_MailInfo_Text'],
+      $_POST['UAM_ConfirmMail_Text'],
+      $_POST['UAM_MailExclusion'],
+      $_POST['UAM_MailExclusion_List'],
+      $_POST['UAM_Password_Enforced'],
+      $_POST['UAM_Password_Score'],
+      $_POST['UAM_AdminPassword_Enforced'],
+      $_POST['UAM_GhostUser_Tracker'],
+      $_POST['UAM_GhostTracker_DayLimit'],
+      $_POST['UAM_GhostTracker_ReminderText'],
+      $_POST['UAM_Add_LastVisit_Column']);
+
+    $conf['nbc_UserAdvManager'] = serialize($newconf_UAM);
+
+		$query = '
+	  	UPDATE '.CONFIG_TABLE.'
+	  	SET value="'.addslashes($conf['nbc_UserAdvManager']).'"
+	  	WHERE param="nbc_UserAdvManager"
+	  	LIMIT 1
+	  	;';
+		
+		pwg_query($query);
+
+
+/* Email confirmation settings */
+    $_POST['UAM_ConfirmMail_ReMail_Txt1'] = str_replace("\'", "'", str_replace("\\\\", "\\", $_POST['UAM_ConfirmMail_ReMail_Txt1']));
+
+    $_POST['UAM_ConfirmMail_ReMail_Txt2'] = str_replace("\'", "'", str_replace("\\\\", "\\", $_POST['UAM_ConfirmMail_ReMail_Txt2']));
+
+/* Control of semicolons - Replaced by dots - Warning message displayed */
+    if ((preg_match($pattern, $_POST['UAM_ConfirmMail_ReMail_Txt1'])) or (preg_match($pattern, $_POST['UAM_ConfirmMail_ReMail_Txt2'])))
+    {
+      if ((preg_match($pattern, $_POST['UAM_ConfirmMail_ReMail_Txt1'])))
+      {
+        $_POST['UAM_ConfirmMail_ReMail_Txt1'] = preg_replace($pattern, $replacement, $_POST['UAM_ConfirmMail_ReMail_Txt1']);
+        $UAM_ConfirmMail_Error_Txt1 = true;
+      }
+      
+      if ((preg_match($pattern, $_POST['UAM_ConfirmMail_ReMail_Txt2'])))
+      {
+        $_POST['UAM_ConfirmMail_ReMail_Txt2'] = preg_replace($pattern, $replacement, $_POST['UAM_ConfirmMail_ReMail_Txt2']);
+        
+        $UAM_ConfirmMail_Error_Txt2 = true;
+      }
+      
+      array_push($page['errors'], l10n('mail_text_error'));
+    }
+
+	  $newconf_UAM_ConfirmMail = array (
+      $_POST['UAM_ConfirmMail_TimeOut'],
+      $_POST['UAM_ConfirmMail_Delay'],
+      $_POST['UAM_ConfirmMail_ReMail_Txt1'],
+      $_POST['UAM_ConfirmMail_Remail'],
+      $_POST['UAM_ConfirmMail_ReMail_Txt2']);
+
+    $conf['nbc_UserAdvManager_ConfirmMail'] = serialize($newconf_UAM_ConfirmMail);
+    
+	  $query = '
+      UPDATE '.CONFIG_TABLE.'
+			SET value="'.addslashes($conf['nbc_UserAdvManager_ConfirmMail']).'"
+			WHERE param="nbc_UserAdvManager_ConfirmMail"
+			LIMIT 1
+		;';
+
+		pwg_query($query);
+
+		array_push($page['infos'], l10n('UAM_save_config'));
+  }
+
+
+/* Testing password enforcement */
+  if (isset($_POST['PasswordTest']) and !is_adviser() and isset($_POST['UAM_Password_Test']) and !empty($_POST['UAM_Password_Test']))
+  {
+    $UAM_Password_Test_Score = testpassword($_POST['UAM_Password_Test']);
+  }
+  else if (isset($_POST['PasswordTest']) and !is_adviser() and empty($_POST['UAM_Password_Test']))
+  {
+    array_push($page['errors'], l10n('reg_err_login3'));
+  }
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+
+/* Group setting for unvalidated and validated users */
+  $groups[-1] = '---------';
+  $No_Valid = -1;
+  $Valid = -1;
+	
+/* Check groups list in database  */
+  $query = '
+SELECT id, name
+FROM '.GROUPS_TABLE.'
+ORDER BY name ASC
+;';
+	
+  $result = pwg_query($query);
+	
+  while ($row = mysql_fetch_assoc($result))
+  {
+    $groups[$row['id']] = $row['name'];
+/* configuration value for unvalidated users */
+    if (isset($conf_UAM[3]) and $conf_UAM[3] == $row['id'])
+    {
+	  	$No_Valid = $row['id'];
+		}
+/* configuration value for validated users */
+    if (isset($conf_UAM[4]) and $conf_UAM[4] == $row['id'])
+		{
+	  	$Valid = $row['id'];
+		}
+  }
+	
+/* Template initialization for unvalidated users group */
+  $template->assign(
+    'No_Confirm_Group',
+   	array(
+	  	'group_options'=> $groups,
+	  	'group_selected' => $No_Valid
+			)
+ 		);
+/* Template initialization for validated users group */
+  $template->assign(
+    'Validated_Group',
+		array(
+      'group_options'=> $groups,
+      'group_selected' => $Valid
+			)
+  	);
+	
+/* Status setting for unvalidated and validated users */
+  $status_options[-1] = '------------';
+  $No_Valid_Status = -1;
+  $Valid_Status = -1;
+	
+/* Get status values */
+  foreach (get_enums(USER_INFOS_TABLE, 'status') as $status)
+  {
+	  $status_options[$status] = l10n('user_status_'.$status);
+	  if (isset($conf_UAM[9]) and $conf_UAM[9] == $status)
+	  {
+	    $No_Valid_Status = $status;
+	  }
+	  
+/* Template initialization for unvalidated users group */
+      $template->assign(
+        'No_Confirm_Status',
+        array(
+					'Status_options' => $status_options,
+		  		'Status_selected' => $No_Valid_Status
+					)
+	  		);
+  }
+  
+/* Get status values */
+  foreach (get_enums(USER_INFOS_TABLE, 'status') as $status)
+  {
+	  $status_options[$status] = l10n('user_status_'.$status);
+	  if (isset($conf_UAM[5]) and $conf_UAM[5] == $status)
+		{
+		  $Valid_Status = $status;
+		}
+		
+/* Template initialization for unvalidated users group */
+      $template->assign(
+	    'Confirm_Status',
+	    array(
+		    'Status_options' => $status_options,
+		    'Status_selected' => $Valid_Status
+		    )
+	    );
+	}
+
+/* Save last opened paragraph in configuration tab */
+  $nb_para=(isset($_POST["nb_para"])) ? $_POST["nb_para"]:"";
+  $nb_para2=(isset($_POST["nb_para2"])) ? $_POST["nb_para2"]:"";
+
+  $conf_UAM_ConfirmMail = unserialize($conf['nbc_UserAdvManager_ConfirmMail']);
+  
+  $template->assign(
+    array(
+    'nb_para'                        => $nb_para,
+    'nb_para2'                       => $nb_para2,
+    'UAM_VERSION'                    => $version,
+    'NBC_UAM_PATH'                   => NBC_UAM_PATH,
+		'UAM_MAIL_INFO_TRUE'             => $conf_UAM[0]=='true' ?  'checked="checked"' : '' ,
+		'UAM_MAIL_INFO_FALSE'            => $conf_UAM[0]=='false' ?  'checked="checked"' : '' ,
+		'UAM_MAILINFO_TEXT'              => $conf_UAM[10],
+		'UAM_NO_CASSE_TRUE'              => $conf_UAM[1]=='true' ?  'checked="checked"' : '' ,
+		'UAM_NO_CASSE_FALSE'             => $conf_UAM[1]=='false' ?  'checked="checked"' : '' ,
+		'UAM_USERNAME_CHAR_TRUE'         => $conf_UAM[7]=='true' ?  'checked="checked"' : '' ,
+		'UAM_USERNAME_CHAR_FALSE'        => $conf_UAM[7]=='false' ?  'checked="checked"' : '' ,
+		'UAM_USERNAME_CHAR_LIST'         => $conf_UAM[8],
+		'UAM_CONFIRM_MAIL_TRUE'          => $conf_UAM[2]=='true' ?  'checked="checked"' : '' ,
+		'UAM_CONFIRM_MAIL_FALSE'         => $conf_UAM[2]=='false' ?  'checked="checked"' : '' ,
+		'UAM_CONFIRMMAIL_TEXT'           => $conf_UAM[11],
+		'UAM_No_Confirm_Group'           => $conf_UAM[3],
+		'UAM_Validated_Group'            => $conf_UAM[4],
+		'UAM_No_Confirm_Status'          => $conf_UAM[9],
+		'UAM_Validated_Status'           => $conf_UAM[5],
+		'UAM_NO_COMMENT_ANO_TRUE'        => $conf_UAM[6]=='true' ?  'checked="checked"' : '' ,
+		'UAM_NO_COMMENT_ANO_FALSE'       => $conf_UAM[6]=='false' ?  'checked="checked"' : '' ,
+		'UAM_MAILEXCLUSION_TRUE'         => $conf_UAM[12]=='true' ?  'checked="checked"' : '' ,
+		'UAM_MAILEXCLUSION_FALSE'        => $conf_UAM[12]=='false' ?  'checked="checked"' : '' ,
+		'UAM_MAILEXCLUSION_LIST'         => $conf_UAM[13],
+		'UAM_PASSWORDENF_TRUE'           => $conf_UAM[14]=='true' ?  'checked="checked"' : '' ,
+		'UAM_PASSWORDENF_FALSE'          => $conf_UAM[14]=='false' ?  'checked="checked"' : '' ,
+		'UAM_PASSWORD_SCORE'             => $conf_UAM[15],
+    'UAM_ADMINPASSWENF_TRUE'         => $conf_UAM[16]=='true' ?  'checked="checked"' : '' ,
+		'UAM_ADMINPASSWENF_FALSE'        => $conf_UAM[16]=='false' ?  'checked="checked"' : '' ,
+    'UAM_GHOSTRACKER_TRUE'           => $conf_UAM[17]=='true' ?  'checked="checked"' : '' ,
+		'UAM_GHOSTRACKER_FALSE'          => $conf_UAM[17]=='false' ?  'checked="checked"' : '' ,
+    'UAM_GHOSTRACKER_DAYLIMIT'       => $conf_UAM[18],
+    'UAM_GHOSTRACKER_REMINDERTEXT'   => $conf_UAM[19],
+    'UAM_ADDLASTVISIT_TRUE'          => $conf_UAM[20]=='true' ?  'checked="checked"' : '' ,
+    'UAM_ADDLASTVISIT_FALSE'         => $conf_UAM[20]=='false' ?  'checked="checked"' : '' ,
+		'UAM_PASSWORD_TEST_SCORE'        => $UAM_Password_Test_Score,
+    'UAM_ERROR_REPORTS1'             => $UAM_MailInfo_Error_Txt,
+    'UAM_ERROR_REPORTS2'             => $UAM_ConfirmMail_Error_Txt,
+    'UAM_ERROR_REPORTS3'             => $UAM_Reminder_Error_Txt,
+    'UAM_ERROR_REPORTS4'             => $UAM_Exclusionlist_Error,
+		'UAM_CONFIRMMAIL_TIMEOUT_TRUE'	 => $conf_UAM_ConfirmMail[0]=='true' ?  'checked="checked"' : '' ,
+		'UAM_CONFIRMMAIL_TIMEOUT_FALSE'  => $conf_UAM_ConfirmMail[0]=='false' ?  'checked="checked"' : '' ,
+		'UAM_CONFIRMMAIL_DELAY'					 => $conf_UAM_ConfirmMail[1],
+    'UAM_CONFIRMMAIL_REMAIL_TRUE'		 => $conf_UAM_ConfirmMail[3]=='true' ? 'checked="checked"' : '',
+    'UAM_CONFIRMMAIL_REMAIL_FALSE'	 => $conf_UAM_ConfirmMail[3]=='false' ? 'checked="checked"' : '',
+    'UAM_CONFIRMMAIL_REMAIL_TXT1'		 => $conf_UAM_ConfirmMail[2],
+    'UAM_CONFIRMMAIL_REMAIL_TXT2'		 => $conf_UAM_ConfirmMail[4],
+    'UAM_ERROR_REPORTS1'             => $UAM_ConfirmMail_Error_Txt1,
+    'UAM_ERROR_REPORTS2'             => $UAM_ConfirmMail_Error_Txt2,
+    )
+  );
+
+  if (isset($_POST['audit']))
+	{
+		$msg_error1 = '';
+		
+/* username insensible a la casse */
+    if (isset($conf_UAM[3]) and $conf_UAM[3] == 'true')
+	  {
+			$query = "
+SELECT ".$conf['user_fields']['username']."
+  FROM ".USERS_TABLE." p1
+WHERE EXISTS(
+  SELECT ".$conf['user_fields']['username']."
+	 FROM ".USERS_TABLE." p2
+	WHERE p1.".$conf['user_fields']['id']." <> p2.".$conf['user_fields']['id']."
+	 AND LOWER(p1.".$conf['user_fields']['username'].") = LOWER(p2.".$conf['user_fields']['username'].")
+	)
+;";
+			  
+		  $result = pwg_query($query);
+			
+		  while($row = mysql_fetch_assoc($result))
+	  	{
+				$msg_error1 .= (($msg_error1 <> '') ? '<br/>' : '') . l10n('Err_audit_no_casse').stripslashes($row['username']);
+			}
+		}
+
+		$msg_error2 = '';
+		
+/* Username without forbidden keys */
+    if ( isset($conf_UAM[7]) and $conf_UAM[7] == 'true' )
+	  {
+			$query = "
+SELECT ".$conf['user_fields']['username'].", ".$conf['user_fields']['email']."
+  FROM ".USERS_TABLE."
+;";
+			  
+			$result = pwg_query($query);
+			
+			while($row = mysql_fetch_assoc($result))
+			{
+				if (!ValidateUsername(stripslashes($row['username'])))
+					$msg_error2 .= (($msg_error2 <> '') ? '<br/>' : '') . l10n('Err_audit_username_char').stripslashes($row['username']);
+			}
+		}
+
+		$msg_error3 = '';
+		
+/* Email without forbidden domain */
+    if ( isset($conf_UAM[12]) and $conf_UAM[12] == 'true' )
+	  {
+			$query = "
+SELECT ".$conf['user_fields']['username'].", ".$conf['user_fields']['email']."
+  FROM ".USERS_TABLE."
+;";
+			  
+		  $result = pwg_query($query);
+			
+		  while($row = mysql_fetch_assoc($result))
+		  {
+			  $conf_nbc_MailExclusion = preg_split("/[\s,]+/",$conf_UAM[13]);
+			  for ($i = 0 ; $i < count($conf_nbc_MailExclusion) ; $i++)
+			  {
+					$pattern = '/'.$conf_nbc_MailExclusion[$i].'/';
+				  if (preg_match($pattern, $row['mail_address']))
+				  {
+						$msg_error3 .=  (($msg_error3 <> '') ? '<br/>' : '') . l10n('Err_audit_email_forbidden').stripslashes($row['username']).' ('.$row['mail_address'].')';
+					}
+				}
+			}
+		}
+		
+    if ($msg_error1 <> '')
+			$errors[] = $msg_error1.'<br/><br/>';
+		
+		if ($msg_error2 <> '')
+			$errors[] = $msg_error2.'<br/><br/>';
+		
+		if ($msg_error3 <> '')
+	  	$errors[] = $msg_error3.'<br/><br/>';
+		
+		if ($msg_error1 <> '' or $msg_error2 <> '' or $msg_error3 <> '')
+	  	array_push($page['errors'], l10n('Err_audit_advise'));
+		else
+    	array_push($page['infos'], l10n('UAM_audit_ok'));
+	}
+
+
+// +-----------------------------------------------------------------------+
+// |                             errors display                            |
+// +-----------------------------------------------------------------------+
+  if (isset ($errors) and count($errors) != 0)
+  {
+	  $template->assign('errors',array());
+	  foreach ($errors as $error)
+	  {
+		  array_push($page['errors'], $error);
+		}
+	}  
+
+// +-----------------------------------------------------------------------+
+// |                           templates display                           |
+// +-----------------------------------------------------------------------+
+  $template->set_filename('plugin_admin_content', dirname(__FILE__) . '/global.tpl');
+  $template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');
+
+  break;
+
+
+// *************************************************************************
+// +-----------------------------------------------------------------------+
+// |                           Users list page                             |
+// +-----------------------------------------------------------------------+
+// *************************************************************************
+  case 'userlist':
+  
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  
+  if (isset($conf_UAM[20]) and $conf_UAM[20]=='true')
+  {
+// +-----------------------------------------------------------------------+
+// |                           initialization                              |
+// +-----------------------------------------------------------------------+
+
+		if (!defined('PHPWG_ROOT_PATH'))
+    {
+    	die('Hacking attempt!');
+    }
+          
+    include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
+
+// +-----------------------------------------------------------------------+
+// | Check Access and exit when user status is not ok                      |
+// +-----------------------------------------------------------------------+
+		check_status(ACCESS_ADMINISTRATOR);
+
+
+// +-----------------------------------------------------------------------+
+// |                               user list                               |
+// +-----------------------------------------------------------------------+
+
+		$page['filtered_users'] = get_user_list();
+
+// +-----------------------------------------------------------------------+
+// |                           Template Init                               |
+// +-----------------------------------------------------------------------+
+		$base_url = PHPWG_ROOT_PATH.'admin.php?page=user_list';
+
+    if (isset($_GET['start']) and is_numeric($_GET['start']))
+    {
+      $start = $_GET['start'];
+    }
+    else
+    {
+      $start = 0;
+    }
+
+// +-----------------------------------------------------------------------+
+// |                            navigation bar                             |
+// +-----------------------------------------------------------------------+
+
+$url = PHPWG_ROOT_PATH.'admin.php'.get_query_string_diff(array('start'));
+
+$navbar = create_navigation_bar(
+  $url,
+  count($page['filtered_users']),
+  $start,
+  $conf['users_page']
+  );
+
+$template->assign('NAVBAR', $navbar);
+
+// +-----------------------------------------------------------------------+
+// |                               user list                               |
+// +-----------------------------------------------------------------------+
+
+    $visible_user_list = array();
+    foreach ($page['filtered_users'] as $num => $local_user)
+    {
+/* simulate LIMIT $start, $conf['users_page'] */
+			if ($num < $start)
+      {
+        continue;
+      }
+      if ($num >= $start + $conf['users_page'])
+      {
+        break;
+      }
+
+      $visible_user_list[] = $local_user;
+		}
+
+		foreach ($visible_user_list as $local_user)
+    {
+      // dates formating and compare
+      $today = date("d-m-Y"); // Get today's date
+      list($day, $month, $year) = explode('-', $today); // explode date of today						 
+      $daytimestamp = mktime(0, 0, 0, $month, $day, $year);// Generate UNIX timestamp
+	  	
+      list($regdate, $regtime) = explode(' ', $local_user['lastvisit']); // Explode date and time from registration date
+      list($regyear, $regmonth, $regday) = explode('-', $regdate); // Explode date from registration date
+      $regtimestamp = mktime(0, 0, 0, $regmonth, $regday, $regyear);// Generate UNIX timestamp
+			
+      $deltasecs = $daytimestamp - $regtimestamp;// Compare the 2 UNIX timestamps	
+      $deltadays = floor($deltasecs / 86400);// Convert result from seconds to days
+      
+      if (isset($conf_UAM[17]) and $conf_UAM[17]=='true' and $conf_UAM[18] <> '')
+      {
+        if ($deltadays <= ($conf_UAM[18]/2))
+        {
+          $display = 'green';
+        }
+        
+        if (($deltadays > ($conf_UAM[18]/2)) and ($deltadays < $conf_UAM[18]))
+        {
+          $display = 'orange';
+        }
+        
+        if ($deltadays >= $conf_UAM[18])
+        {
+          $display = 'red';
+        }
+        
+      }
+      /* Plugin version inserted */
+      $template->assign(
+        array(
+          'UAM_VERSION' => $version,
+          'NBC_UAM_PATH'=> NBC_UAM_PATH,
+          )
+        );
+
+   		$template->append(
+     		'users',
+       	array(
+       		'ID'          => $local_user['id'],
+         	'USERNAME'    => stripslashes($local_user['username']),
+					'EMAIL'       => get_email_address_as_display_text($local_user['email']),
+          'LASTVISIT'   => $local_user['lastvisit'],
+          'DAYS'        => $deltadays,
+          'DISPLAY'     => $display,
+				)
+			);
+		}
+// +-----------------------------------------------------------------------+
+// |                             errors display                            |
+// +-----------------------------------------------------------------------+
+		if ( isset ($errors) and count($errors) != 0)
+		{
+	  	$template->assign('errors',array());
+			foreach ($errors as $error)
+	  	{
+				array_push($page['errors'], $error);
+	  	}
+ 		}  
+
+// +-----------------------------------------------------------------------+
+// |                           templates display                           |
+// +-----------------------------------------------------------------------+
+		$template->set_filename('plugin_admin_content', dirname(__FILE__) . '/userlist.tpl');
+    $template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');		
+  }
+  else
+  {
+		array_push($page['infos'], l10n('Err_Userlist_Settings'));
+  }
+  break;
+
+
+// *************************************************************************
+// +-----------------------------------------------------------------------+
+// |                           Users manager page                          |
+// +-----------------------------------------------------------------------+
+// *************************************************************************
+  case 'usermanager':
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+
+  $conf_UAM_ConfirmMail = unserialize($conf['nbc_UserAdvManager_ConfirmMail']);
+	
+  if (isset($conf_UAM[2]) and $conf_UAM[2]=='true' and ((isset($conf_UAM[3]) and $conf_UAM[3] <> '-1') or (isset($conf_UAM[9]) and $conf_UAM[9] <> '-1')) and isset($conf_UAM_ConfirmMail[0]) and $conf_UAM_ConfirmMail[0]=='true')
+  {
+// +-----------------------------------------------------------------------+
+// |                           initialization                              |
+// +-----------------------------------------------------------------------+
+
+		if (!defined('PHPWG_ROOT_PATH'))
+    {
+    	die('Hacking attempt!');
+    }
+          
+    include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
+
+// +-----------------------------------------------------------------------+
+// | Check Access and exit when user status is not ok                      |
+// +-----------------------------------------------------------------------+
+		check_status(ACCESS_ADMINISTRATOR);
+
+// +-----------------------------------------------------------------------+
+// |                               user list                               |
+// +-----------------------------------------------------------------------+
+
+		$page['filtered_users'] = get_unvalid_user_list();
+
+// +-----------------------------------------------------------------------+
+// |                            selected users                             |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Del_Selected']))
+		{
+  		$collection = array();
+
+			switch ($_POST['target'])
+    	{
+    		case 'all' :
+      	{
+      		foreach($page['filtered_users'] as $local_user)
+        	{
+        		array_push($collection, $local_user['id']);
+        	}
+					break;
+				}
+      	case 'selection' :
+      	{
+      		if (isset($_POST['selection']))
+        	{
+        		$collection = $_POST['selection'];
+        	}
+        	break;
+      	}
+			}
+
+			if (count($collection) == 0)
+    	{
+    		array_push($page['errors'], l10n('Select at least one user'));
+   		}
+		}
+
+// +-----------------------------------------------------------------------+
+// |                             delete users                              |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Del_Selected']) and count($collection) > 0)
+  	{
+  		if (in_array($conf['guest_id'], $collection))
+   		{
+    		array_push($page['errors'], l10n('Guest cannot be deleted'));
+    	}
+    	if (($conf['guest_id'] != $conf['default_user_id']) and
+    		in_array($conf['default_user_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('Default user cannot be deleted'));
+    	}
+    	if (in_array($conf['webmaster_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('Webmaster cannot be deleted'));
+    	}
+    	if (in_array($user['id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('You cannot delete your account'));
+    	}
+
+			if (count($page['errors']) == 0)
+    	{
+    		foreach ($collection as $user_id)
+      	{
+      		delete_user($user_id);
+      	}
+     		array_push(
+      		$page['infos'],
+        	l10n_dec(
+        	'%d user deleted', '%d users deleted',
+        	count($collection)
+        	)
+      	);
+
+      	foreach ($page['filtered_users'] as $filter_key => $filter_user)
+      	{
+      		if (in_array($filter_user['id'], $collection))
+        	{
+        		unset($page['filtered_users'][$filter_key]);
+        	}
+     		}
+			}
+		}
+
+// +-----------------------------------------------------------------------+
+// |                 Resend new validation key to users                    |
+// +-----------------------------------------------------------------------+
+// +-----------------------------------------------------------------------+
+// |                            selected users                             |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Mail_With_Key']))
+		{
+  		$collection = array();
+
+			switch ($_POST['target'])
+    	{
+    		case 'all' :
+      	{
+      		foreach($page['filtered_users'] as $local_user)
+        	{
+        		array_push($collection, $local_user['id']);
+        	}
+        	break;
+				}
+      	case 'selection' :
+      	{
+      		if (isset($_POST['selection']))
+        	{
+        		$collection = $_POST['selection'];
+        	}
+        	break;
+      	}
+			}
+
+    	if (count($collection) == 0)
+    	{
+    		array_push($page['errors'], l10n('Select at least one user'));
+    	}
+		}
+// +-----------------------------------------------------------------------+
+// |                 Resend new validation key to users                    |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Mail_With_Key']) and count($collection) > 0)
+		{
+			if (in_array($conf['guest_id'], $collection))
+   		{
+    		array_push($page['errors'], l10n('No_validation_for_Guest'));
+    	}
+    	if (($conf['guest_id'] != $conf['default_user_id']) and
+    		in_array($conf['default_user_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_default_user'));
+    	}
+   		if (in_array($conf['webmaster_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_Webmaster'));
+    	}
+    	if (in_array($user['id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_your_account'));
+    	}
+
+    	if (count($page['errors']) == 0)
+    	{
+    		foreach ($collection as $user_id)
+      	{     	
+      		$typemail = 1;
+				  $query = "
+SELECT id, username, mail_address
+  FROM ".USERS_TABLE."
+WHERE id = '".$user_id."'
+;";
+					$data = mysql_fetch_assoc(pwg_query($query));
+				
+      		ResendMail2User($typemail,$user_id,stripslashes($data['username']),$data['mail_address'],true);
+      	}
+      	array_push(
+      		$page['infos'],
+        	l10n_dec(
+        		'%d_Mail_With_Key', '%d_Mails_With_Key',
+        	count($collection)
+        	)
+      	);
+      	
+				$page['filtered_users'] = get_unvalid_user_list();
+			}
+		}
+
+// +-----------------------------------------------------------------------+
+// |             Send reminder without new key to users                    |
+// +-----------------------------------------------------------------------+
+// +-----------------------------------------------------------------------+
+// |                            selected users                             |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Mail_Without_Key']))
+		{
+  		$collection = array();
+
+			switch ($_POST['target'])
+    	{
+    		case 'all' :
+      	{
+      		foreach($page['filtered_users'] as $local_user)
+        	{
+        		array_push($collection, $local_user['id']);
+        	}
+        	break;
+				}
+      	case 'selection' :
+      	{
+      		if (isset($_POST['selection']))
+        	{
+        		$collection = $_POST['selection'];
+        	}
+        	break;
+      	}
+			}
+
+    	if (count($collection) == 0)
+    	{
+    		array_push($page['errors'], l10n('Select at least one user'));
+    	}
+		}
+// +-----------------------------------------------------------------------+
+// |             Send reminder without new key to users                    |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Mail_Without_Key']) and count($collection) > 0)
+		{
+			if (in_array($conf['guest_id'], $collection))
+   		{
+    		array_push($page['errors'], l10n('No_validation_for_Guest'));
+    	}
+    	if (($conf['guest_id'] != $conf['default_user_id']) and
+    		in_array($conf['default_user_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_default_user'));
+    	}
+   		if (in_array($conf['webmaster_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_Webmaster'));
+    	}
+    	if (in_array($user['id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_your_account'));
+    	}
+
+    	if (count($page['errors']) == 0)
+    	{
+    		foreach ($collection as $user_id)
+      	{
+      		$typemail = 2;
+				  $query = "
+SELECT id, username, mail_address
+  FROM ".USERS_TABLE."
+WHERE id = '".$user_id."'
+;";
+					
+					$data = mysql_fetch_assoc(pwg_query($query));
+				
+      		ResendMail2User($typemail,$user_id,stripslashes($data['username']),$data['mail_address'],false);				
+      	}
+      	array_push(
+      		$page['infos'],
+        	l10n_dec(
+        		'%d_Reminder_Sent', '%d_Reminders_Sent',
+       		count($collection)
+        	)
+      	);
+        
+				$page['filtered_users'] = get_unvalid_user_list();
+			}
+		}
+
+// +-----------------------------------------------------------------------+
+// |             								Force validation					                 |
+// +-----------------------------------------------------------------------+
+// +-----------------------------------------------------------------------+
+// |                            selected users                             |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Force_Validation']))
+		{
+  		$collection = array();
+
+			switch ($_POST['target'])
+    	{
+    		case 'all' :
+      	{
+      		foreach($page['filtered_users'] as $local_user)
+        	{
+        		array_push($collection, $local_user['id']);
+        	}
+        	break;
+				}
+      	case 'selection' :
+      	{
+      		if (isset($_POST['selection']))
+        	{
+        		$collection = $_POST['selection'];
+        	}
+        	break;
+      	}
+			}
+
+    	if (count($collection) == 0)
+    	{
+    		array_push($page['errors'], l10n('Select at least one user'));
+    	}
+		}
+// +-----------------------------------------------------------------------+
+// |             								Force validation					                 |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Force_Validation']) and count($collection) > 0)
+		{
+			if (in_array($conf['guest_id'], $collection))
+   		{
+    		array_push($page['errors'], l10n('No_validation_for_Guest'));
+    	}
+    	if (($conf['guest_id'] != $conf['default_user_id']) and
+    		in_array($conf['default_user_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_default_user'));
+    	}
+   		if (in_array($conf['webmaster_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_Webmaster'));
+    	}
+    	if (in_array($user['id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_validation_for_your_account'));
+    	}
+
+    	if (count($page['errors']) == 0)
+    	{
+    		foreach ($collection as $user_id)
+      	{
+				  $query = "
+SELECT id, username, mail_address
+  FROM ".USERS_TABLE."
+WHERE id = '".$user_id."'
+;";
+					
+					$data = mysql_fetch_assoc(pwg_query($query));
+				
+      		ForceValidation($data['id']);				
+      	}
+      	array_push(
+      		$page['infos'],
+        	l10n_dec(
+        		'%d_Validated_User', '%d_Validated_Users',
+       		count($collection)
+        	)
+      	);
+
+				$page['filtered_users'] = get_unvalid_user_list();
+			}
+		}
+		
+
+// +-----------------------------------------------------------------------+
+// |                              groups list                              |
+// +-----------------------------------------------------------------------+
+
+		$groups[-1] = '------------';
+
+    $query = '
+SELECT id, name
+  FROM '.GROUPS_TABLE.'
+ORDER BY name ASC
+;';
+
+		$result = pwg_query($query);
+          
+    while ($row = mysql_fetch_assoc($result))
+    {
+      $groups[$row['id']] = $row['name'];
+    }
+
+// +-----------------------------------------------------------------------+
+// |                           Template Init                               |
+// +-----------------------------------------------------------------------+
+		$base_url = PHPWG_ROOT_PATH.'admin.php?page=user_list';
+
+    if (isset($_GET['start']) and is_numeric($_GET['start']))
+    {
+      $start = $_GET['start'];
+    }
+    else
+    {
+      $start = 0;
+    }
+
+/* Hide radio-button if not allow to assign adviser */
+		if ($conf['allow_adviser'])
+    	{
+      	$template->assign('adviser', true);
+    	}
+
+// +-----------------------------------------------------------------------+
+// |                            navigation bar                             |
+// +-----------------------------------------------------------------------+
+
+$url = PHPWG_ROOT_PATH.'admin.php'.get_query_string_diff(array('start'));
+
+$navbar = create_navigation_bar(
+  $url,
+  count($page['filtered_users']),
+  $start,
+  $conf['users_page']
+  );
+
+$template->assign('NAVBAR', $navbar);
+
+// +-----------------------------------------------------------------------+
+// |                               user list                               |
+// +-----------------------------------------------------------------------+
+
+		$profile_url = get_root_url().'admin.php?page=profile&amp;user_id=';
+		$perm_url = get_root_url().'admin.php?page=user_perm&amp;user_id=';
+
+    $visible_user_list = array();
+    foreach ($page['filtered_users'] as $num => $local_user)
+    {
+/* simulate LIMIT $start, $conf['users_page'] */
+			if ($num < $start)
+      {
+        continue;
+      }
+      if ($num >= $start + $conf['users_page'])
+      {
+        break;
+      }
+
+      $visible_user_list[] = $local_user;
+		}
+
+		foreach ($visible_user_list as $local_user)
+    {
+      $groups_string = preg_replace(
+      	'/(\d+)/e',
+        "\$groups['$1']",
+        implode(
+        	', ',
+            $local_user['groups']
+         )
+			);
+
+      $query = '
+SELECT user_id, reminder
+FROM '.USER_CONFIRM_MAIL_TABLE.'
+WHERE user_id = '.$local_user['id'].'
+;';
+      $result = pwg_query($query);
+      
+      $row = mysql_fetch_assoc($result);
+    
+      if (isset($row['reminder']) and $row['reminder'] == 'true')
+      {
+        $reminder = l10n('Reminder_Sent_OK');
+      }
+      else if ((isset($row['reminder']) and $row['reminder'] == 'false') or !isset($row['reminder']))
+      {
+        $reminder = l10n('Reminder_Sent_NOK');
+      }
+
+
+	  	if (isset($_POST['pref_submit'])
+    		and isset($_POST['selection'])
+      	and in_array($local_user['id'], $_POST['selection']))
+	  	{
+				$checked = 'checked="checked"';
+	  	}
+			else
+    	{
+    		$checked = '';
+    	}
+
+    	$properties = array();
+    	if ( $local_user['level'] != 0 )
+			{
+    		$properties[] = l10n( sprintf('Level %d', $local_user['level']) );
+			}
+    	$properties[] =
+    		(isset($local_user['enabled_high']) and ($local_user['enabled_high'] == 'true'))
+      		? l10n('is_high_enabled') : l10n('is_high_disabled');
+
+			$expiration = expiration($local_user['id']);
+
+   		$template->append(
+     		'users',
+       	array(
+       		'ID'               => $local_user['id'],
+         	'CHECKED'          => $checked,
+         	'U_PROFILE'        => $profile_url.$local_user['id'],
+         	'U_PERM'           => $perm_url.$local_user['id'],
+         	'USERNAME'         => stripslashes($local_user['username'])
+                                  .($local_user['id'] == $conf['guest_id']
+                                  ? '<BR>['.l10n('is_the_guest').']' : '')
+                                  .($local_user['id'] == $conf['default_user_id']
+                                  ? '<BR>['.l10n('is_the_default').']' : ''),
+                                  'STATUS' => l10n('user_status_'
+                                  .$local_user['status']).(($local_user['adviser'] == 'true')
+                                  ? '<BR>['.l10n('adviser').']' : ''),
+					'EMAIL'            => get_email_address_as_display_text($local_user['email']),
+         	'GROUPS'           => $groups_string,
+         	'REGISTRATION'     => $local_user['registration_date'],
+          'REMINDER'         => $reminder,    
+         	'EXPIRATION'       => $expiration,
+				)
+			);
+		}
+    /* Plugin version inserted */
+    $template->assign(
+      array(
+        'UAM_VERSION'      => $version,
+        'NBC_UAM_PATH'     => NBC_UAM_PATH,
+      )
+    );
+
+// +-----------------------------------------------------------------------+
+// |                             errors display                            |
+// +-----------------------------------------------------------------------+
+		if ( isset ($errors) and count($errors) != 0)
+		{
+	  	$template->assign('errors',array());
+			foreach ($errors as $error)
+	  	{
+				array_push($page['errors'], $error);
+	  	}
+		}  
+
+// +-----------------------------------------------------------------------+
+// |                           templates display                           |
+// +-----------------------------------------------------------------------+
+		$template->set_filename('plugin_admin_content', dirname(__FILE__) . '/usermanager.tpl');
+    $template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');		
+	}
+  else
+  {
+		array_push($page['infos'], l10n('Err_UserManager_Settings'));
+  }
+  break;
+
+
+// *************************************************************************
+// +-----------------------------------------------------------------------+
+// |                           Ghost Tracker page                          |
+// +-----------------------------------------------------------------------+
+// *************************************************************************
+  case 'ghosttracker':
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+	
+  if (isset($conf_UAM[17]) and $conf_UAM[17]=='true')
+  {
+// +-----------------------------------------------------------------------+
+// |                           initialization                              |
+// +-----------------------------------------------------------------------+
+
+		if (!defined('PHPWG_ROOT_PATH'))
+    {
+    	die('Hacking attempt!');
+    }
+          
+    include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
+
+// +-----------------------------------------------------------------------+
+// | Check Access and exit when user status is not ok                      |
+// +-----------------------------------------------------------------------+
+		check_status(ACCESS_ADMINISTRATOR);
+
+// +-----------------------------------------------------------------------+
+// |                               user list                               |
+// +-----------------------------------------------------------------------+
+
+		$page['filtered_users'] = get_ghost_user_list();
+
+// +-----------------------------------------------------------------------+
+// |                            selected users                             |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Del_Selected']))
+		{
+  		$collection = array();
+
+			switch ($_POST['target'])
+    	{
+    		case 'all' :
+      	{
+      		foreach($page['filtered_users'] as $local_user)
+        	{
+        		array_push($collection, $local_user['id']);
+        	}
+					break;
+				}
+      	case 'selection' :
+      	{
+      		if (isset($_POST['selection']))
+        	{
+        		$collection = $_POST['selection'];
+        	}
+        	break;
+      	}
+			}
+
+			if (count($collection) == 0)
+    	{
+    		array_push($page['errors'], l10n('Select at least one user'));
+   		}
+		}
+
+// +-----------------------------------------------------------------------+
+// |                             delete users                              |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Del_Selected']) and count($collection) > 0)
+  	{
+  		if (in_array($conf['guest_id'], $collection))
+   		{
+    		array_push($page['errors'], l10n('Guest cannot be deleted'));
+    	}
+    	if (($conf['guest_id'] != $conf['default_user_id']) and
+    		in_array($conf['default_user_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('Default user cannot be deleted'));
+    	}
+    	if (in_array($conf['webmaster_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('Webmaster cannot be deleted'));
+    	}
+    	if (in_array($user['id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('You cannot delete your account'));
+    	}
+
+			if (count($page['errors']) == 0)
+    	{
+    		foreach ($collection as $user_id)
+      	{
+      		delete_user($user_id);
+      	}
+     		array_push(
+      		$page['infos'],
+        	l10n_dec(
+        	'%d user deleted', '%d users deleted',
+        	count($collection)
+        	)
+      	);
+
+      	foreach ($page['filtered_users'] as $filter_key => $filter_user)
+      	{
+      		if (in_array($filter_user['id'], $collection))
+        	{
+        		unset($page['filtered_users'][$filter_key]);
+        	}
+     		}
+			}
+		}
+
+// +-----------------------------------------------------------------------+
+// |                          Send ghost reminder                          |
+// +-----------------------------------------------------------------------+
+// +-----------------------------------------------------------------------+
+// |                            selected users                             |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Reminder_Email']))
+		{
+  		$collection = array();
+
+			switch ($_POST['target'])
+    	{
+    		case 'all' :
+      	{
+      		foreach($page['filtered_users'] as $local_user)
+        	{
+        		array_push($collection, $local_user['id']);
+        	}
+        	break;
+				}
+      	case 'selection' :
+      	{
+      		if (isset($_POST['selection']))
+        	{
+        		$collection = $_POST['selection'];
+        	}
+        	break;
+      	}
+			}
+
+    	if (count($collection) == 0)
+    	{
+    		array_push($page['errors'], l10n('Select at least one user'));
+    	}
+		}
+// +-----------------------------------------------------------------------+
+// |                         Send ghost reminder                           |
+// +-----------------------------------------------------------------------+
+		if (isset($_POST['Reminder_Email']) and count($collection) > 0)
+		{
+			if (in_array($conf['guest_id'], $collection))
+   		{
+    		array_push($page['errors'], l10n('No_reminder_for_Guest'));
+    	}
+    	if (($conf['guest_id'] != $conf['default_user_id']) and
+    		in_array($conf['default_user_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_reminder_for_default_user'));
+    	}
+   		if (in_array($conf['webmaster_id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_reminder_for_Webmaster'));
+    	}
+    	if (in_array($user['id'], $collection))
+    	{
+    		array_push($page['errors'], l10n('No_reminder_for_your_account'));
+    	}
+
+    	if (count($page['errors']) == 0)
+    	{
+    		foreach ($collection as $user_id)
+      	{
+				  $query = "
+SELECT id, username, mail_address
+  FROM ".USERS_TABLE."
+WHERE id = '".$user_id."'
+;";
+					
+					$data = mysql_fetch_assoc(pwg_query($query));
+				
+      		ghostreminder($user_id,stripslashes($data['username']),$data['mail_address']);				
+      	}
+      	array_push(
+      		$page['infos'],
+        	l10n_dec(
+        		'%d_Reminder_Sent', '%d_Reminders_Sent',
+       		count($collection)
+        	)
+      	);
+      	
+				$page['filtered_users'] = get_ghost_user_list();
+			}
+		}
+    
+    if (isset($_POST['GhostTracker_Init']))
+    {
+      /* Reset is only allowed for admins ! */
+      if (is_admin() and !is_adviser())
+      {
+        $query1 = '
+SELECT *
+  FROM '.USER_LASTVISIT_TABLE.';';
+
+        $count = mysql_num_rows(pwg_query($query1));
+
+        if ($count <> 0)
+        {
+          $query = '
+SELECT DISTINCT u.id,
+                ui.status AS status
+FROM '.USERS_TABLE.' AS u
+  INNER JOIN '.USER_INFOS_TABLE.' AS ui
+    ON u.id = ui.user_id
+WHERE u.id NOT IN (SELECT user_id FROM '.USER_LASTVISIT_TABLE.')
+  AND status != "webmaster"
+  AND status != "guest"
+  AND status != "admin"
+ORDER BY u.id ASC
+;';
+
+          $result = pwg_query($query);
+          
+          while ($row = mysql_fetch_assoc($result))
+          {
+            list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+            
+            $query = "
+INSERT INTO ".USER_LASTVISIT_TABLE." (user_id, lastvisit, reminder)
+VALUES ('".$row['id']."','".$dbnow."','false')
+;";
+            pwg_query($query);
+          }
+        }
+        else if ($count == 0)
+        {
+          $query = '
+SELECT DISTINCT u.id,
+                ui.status AS status
+FROM '.USERS_TABLE.' AS u
+  INNER JOIN '.USER_INFOS_TABLE.' AS ui
+    ON u.id = ui.user_id
+WHERE status != "webmaster"
+  AND status != "guest"
+  AND status != "admin"
+ORDER BY u.id ASC
+;';
+
+          $result = pwg_query($query);
+          
+          while($row = mysql_fetch_assoc($result))
+          {
+            list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+            
+            $query = "
+INSERT INTO ".USER_LASTVISIT_TABLE." (user_id, lastvisit, reminder)
+VALUES ('".$row['id']."','".$dbnow."','false')
+;";
+            pwg_query($query);
+          }
+        }
+        
+        array_push($page['infos'], l10n('GhostTracker_Init_OK'));
+      }
+    }
+
+// +-----------------------------------------------------------------------+
+// |                           Template Init                               |
+// +-----------------------------------------------------------------------+
+		$base_url = PHPWG_ROOT_PATH.'admin.php?page=user_list';
+
+    if (isset($_GET['start']) and is_numeric($_GET['start']))
+    {
+      $start = $_GET['start'];
+    }
+    else
+    {
+      $start = 0;
+    }
+
+/* Hide radio-button if not allow to assign adviser */
+		if ($conf['allow_adviser'])
+    {
+      $template->assign('adviser', true);
+   	}
+
+// +-----------------------------------------------------------------------+
+// |                            navigation bar                             |
+// +-----------------------------------------------------------------------+
+
+$url = PHPWG_ROOT_PATH.'admin.php'.get_query_string_diff(array('start'));
+
+$navbar = create_navigation_bar(
+  $url,
+  count($page['filtered_users']),
+  $start,
+  $conf['users_page']
+  );
+
+$template->assign('NAVBAR', $navbar);
+
+// +-----------------------------------------------------------------------+
+// |                               user list                               |
+// +-----------------------------------------------------------------------+
+
+    $visible_user_list = array();
+    foreach ($page['filtered_users'] as $num => $local_user)
+    {
+/* simulate LIMIT $start, $conf['users_page'] */
+			if ($num < $start)
+      {
+        continue;
+      }
+      if ($num >= $start + $conf['users_page'])
+      {
+        break;
+      }
+
+      $visible_user_list[] = $local_user;
+		}
+
+/* Plugin version inserted */
+      $template->assign(
+        array(
+          'UAM_VERSION'      => $version,
+          'NBC_UAM_PATH'     => NBC_UAM_PATH,
+        )
+      );
+
+		foreach ($visible_user_list as $local_user)
+    {
+      $reminder = '';
+    
+      if (isset($local_user['reminder']) and $local_user['reminder'] == 'true')
+      {
+        $reminder = l10n('Reminder_Sent_OK');
+      }
+      else if (isset($local_user['reminder']) and $local_user['reminder'] == 'false')
+      {
+        $reminder = l10n('Reminder_Sent_NOK');
+      }
+    
+      if (isset($_POST['pref_submit']) and isset($_POST['selection']) and in_array($local_user['id'], $_POST['selection']))
+	  	{
+				$checked = 'checked="checked"';
+	  	}
+			else
+    	{
+    		$checked = '';
+    	}
+
+      $template->append(
+     	  'users',
+       	array(
+       		'ID'          => $local_user['id'],
+         	'CHECKED'     => $checked,
+         	'USERNAME'    => stripslashes($local_user['username']),
+					'EMAIL'       => get_email_address_as_display_text($local_user['email']),
+          'LASTVISIT'   => $local_user['lastvisit'],
+          'REMINDER'    => $reminder,
+				)
+			);
+		}
+
+// +-----------------------------------------------------------------------+
+// |                             errors display                            |
+// +-----------------------------------------------------------------------+
+		if ( isset ($errors) and count($errors) != 0)
+		{
+	  	$template->assign('errors',array());
+			foreach ($errors as $error)
+	  	{
+				array_push($page['errors'], $error);
+	  	}
+		}  
+
+// +-----------------------------------------------------------------------+
+// |                           templates display                           |
+// +-----------------------------------------------------------------------+
+		$template->set_filename('plugin_admin_content', dirname(__FILE__) . '/ghosttracker.tpl');
+    $template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');		
+	}
+  else
+  {
+		array_push($page['infos'], l10n('Err_GhostTracker_Settings'));
+  }
+
+  break;
+}
+?>
Index: /extensions/NBC_UserAdvManager/trunk/admin/ghosttracker.tpl
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/admin/ghosttracker.tpl	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/admin/ghosttracker.tpl	(revision 5056)
@@ -17,10 +17,10 @@
 </div>
 
-<form method="post" action="{$UserAdvManager_F_ACTION}" class="general">
+<form method="post" action="{$UAM_F_ACTION}" class="general">
   <fieldset>
   	<legend>{'GT_Init'|@translate}</legend>
     <ul>
 		  <li>
-        <label>{'UserAdvManager_GhostTracker_Init'|@translate}</label><br><br>
+        <label>{'UAM_GhostTracker_Init'|@translate}</label><br><br>
       </li>
     </ul>
Index: /extensions/NBC_UserAdvManager/trunk/admin/global.tpl
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/admin/global.tpl	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/admin/global.tpl	(revision 5056)
@@ -29,5 +29,5 @@
 </div>
 
-<form method="post" action="{$UserAdvManager_F_ACTION}" class="general">
+<form method="post" action="{$UAM_F_ACTION}" class="general">
 
 <p><input class="submit" type="submit" value="{'submit'|@translate}" name="submit" {$TAG_INPUT_ENABLED} >&nbsp;<input class="submit" type="submit" value="{'audit'|@translate}" name="audit"></p>
@@ -39,5 +39,5 @@
 
   <div id="config1_header" class="instructionBlockHeaderCollapsed" onclick="nbc_blockToggleDisplay('config1_header', 'Config1')">
-    <span class="cluetip" title="{'UAM_restricTitle'|translate}|{'UAM_restricTitle_d'|translate}">{'UserAdvManager_Title1'|@translate}</span>
+    <span class="cluetip" title="{'UAM_restricTitle'|translate}|{'UAM_restricTitle_d'|translate}">{'UAM_Title1'|@translate}</span>
   </div>
 
@@ -45,44 +45,44 @@
   <fieldset>
     <ul>
-    	<li><label class="cluetip" title="{'UAM_casenTitle'|translate}|{'UAM_casenTitle_d'|translate}">{'UserAdvManager_No_Casse'|@translate}</label><br><br>
-        <input type="radio" value="false" {$UserAdvManager_NO_CASSE_FALSE} name="UserAdvManager_No_Casse">{'UserAdvManager_No_Casse_false'|@translate}<br>
-        <input type="radio" value="true" {$UserAdvManager_NO_CASSE_TRUE} name="UserAdvManager_No_Casse">{'UserAdvManager_No_Casse_true'|@translate}<br><br>
+    	<li><label class="cluetip" title="{'UAM_casenTitle'|translate}|{'UAM_casenTitle_d'|translate}">{'UAM_No_Casse'|@translate}</label><br><br>
+        <input type="radio" value="false" {$UAM_NO_CASSE_FALSE} name="UAM_No_Casse">{'UAM_No_Casse_false'|@translate}<br>
+        <input type="radio" value="true" {$UAM_NO_CASSE_TRUE} name="UAM_No_Casse">{'UAM_No_Casse_true'|@translate}<br><br>
    		</li>
       
-    	<li><label class="cluetip" title="{'UAM_carexcTitle'|translate}|{'UAM_carexcTitle_d'|translate}">{'UserAdvManager_Username_Char'|@translate}</label><br><br>
-        <input type="radio" value="false" {$UserAdvManager_USERNAME_CHAR_FALSE} name="UserAdvManager_Username_Char">{'UserAdvManager_Username_Char_false'|@translate}<br>
-        <input type="radio" value="true" {$UserAdvManager_USERNAME_CHAR_TRUE} name="UserAdvManager_Username_Char">{'UserAdvManager_Username_Char_true'|@translate}
-        <div id="uam_leftmargin"><input type="text" name="UserAdvManager_Username_List" value="{$UserAdvManager_USERNAME_CHAR_LIST}" size="20" style="text-align: center;"></div><br><br>
+    	<li><label class="cluetip" title="{'UAM_carexcTitle'|translate}|{'UAM_carexcTitle_d'|translate}">{'UAM_Username_Char'|@translate}</label><br><br>
+        <input type="radio" value="false" {$UAM_USERNAME_CHAR_FALSE} name="UAM_Username_Char">{'UAM_Username_Char_false'|@translate}<br>
+        <input type="radio" value="true" {$UAM_USERNAME_CHAR_TRUE} name="UAM_Username_Char">{'UAM_Username_Char_true'|@translate}
+        <div id="uam_leftmargin"><input type="text" name="UAM_Username_List" value="{$UAM_USERNAME_CHAR_LIST}" size="20" style="text-align: center;"></div><br><br>
     	</li>
       
-    	<li><label class="cluetip" title="{'UAM_passwTitle'|translate}|{'UAM_passwTitle_d'|translate}">{'UserAdvManager_Password_Enforced'|@translate}</label><br><br>
-        <input type="radio" value="false" {$UserAdvManager_PASSWORDENF_FALSE} name="UserAdvManager_Password_Enforced">{'UserAdvManager_Password_Enforced_false'|@translate}<br>
-        <input type="radio" value="true" {$UserAdvManager_PASSWORDENF_TRUE} name="UserAdvManager_Password_Enforced">{'UserAdvManager_Password_Enforced_true'|@translate}&nbsp;<input type="text" name="UserAdvManager_Password_Score" value="{$UserAdvManager_PASSWORD_SCORE}" size="5" style="text-align: center;"><br><br>
-
-        {'UserAdvManager_PasswordTest'|@translate}<input class="cluetip" title="{'UAM_passwtestTitle'|translate}|{'UAM_passwtestTitle_d'|translate}" type="text" name="UserAdvManager_Password_Test" value="{$UserAdvManager_PASSWORD_TEST}" size="50" style="text-align: left;">&nbsp;&nbsp;&nbsp;
+    	<li><label class="cluetip" title="{'UAM_passwTitle'|translate}|{'UAM_passwTitle_d'|translate}">{'UAM_Password_Enforced'|@translate}</label><br><br>
+        <input type="radio" value="false" {$UAM_PASSWORDENF_FALSE} name="UAM_Password_Enforced">{'UAM_Password_Enforced_false'|@translate}<br>
+        <input type="radio" value="true" {$UAM_PASSWORDENF_TRUE} name="UAM_Password_Enforced">{'UAM_Password_Enforced_true'|@translate}&nbsp;<input type="text" name="UAM_Password_Score" value="{$UAM_PASSWORD_SCORE}" size="5" style="text-align: center;"><br><br>
+
+        {'UAM_PasswordTest'|@translate}<input class="cluetip" title="{'UAM_passwtestTitle'|translate}|{'UAM_passwtestTitle_d'|translate}" type="text" name="UAM_Password_Test" value="{$UAM_PASSWORD_TEST}" size="50" style="text-align: left;">&nbsp;&nbsp;&nbsp;
         <input class="submit" type="submit" value="{'PasswordTest'|@translate}" name="PasswordTest">&nbsp;&nbsp;&nbsp;
-        {'UserAdvManager_ScoreTest'|@translate}{$UserAdvManager_PASSWORD_TEST_SCORE}<br><br>
+        {'UAM_ScoreTest'|@translate}{$UAM_PASSWORD_TEST_SCORE}<br><br>
     	</li>
 
       <ul>
-      <li><label class="cluetip" title="{'UAM_passwadmTitle'|translate}|{'UAM_passwadmTitle_d'|translate}">{'UserAdvManager_AdminPassword_Enforced'|@translate}</label><br><br>
-        <input type="radio" value="false" {$UserAdvManager_ADMINPASSWENF_FALSE} name="UserAdvManager_AdminPassword_Enforced">{'UserAdvManager_AdminPassword_Enforced_false'|@translate}<br>        
-        <input type="radio" value="true" {$UserAdvManager_ADMINPASSWENF_TRUE} name="UserAdvManager_AdminPassword_Enforced">{'UserAdvManager_AdminPassword_Enforced_true'|@translate}<br><br>
+      <li><label class="cluetip" title="{'UAM_passwadmTitle'|translate}|{'UAM_passwadmTitle_d'|translate}">{'UAM_AdminPassword_Enforced'|@translate}</label><br><br>
+        <input type="radio" value="false" {$UAM_ADMINPASSWENF_FALSE} name="UAM_AdminPassword_Enforced">{'UAM_AdminPassword_Enforced_false'|@translate}<br>        
+        <input type="radio" value="true" {$UAM_ADMINPASSWENF_TRUE} name="UAM_AdminPassword_Enforced">{'UAM_AdminPassword_Enforced_true'|@translate}<br><br>
       </li>
       </ul>
       
-    	<li><label class="cluetip" title="{'UAM_mailexcTitle'|translate}|{'UAM_mailexcTitle_d'|translate}">{'UserAdvManager_MailExclusion'|@translate}</label><br><br>
-        <input type="radio" value="false" {$UserAdvManager_MAILEXCLUSION_FALSE} name="UserAdvManager_MailExclusion">{'UserAdvManager_MailExclusion_false'|@translate}<br>
-        <input type="radio" value="true" {$UserAdvManager_MAILEXCLUSION_TRUE} name="UserAdvManager_MailExclusion">{'UserAdvManager_MailExclusion_true'|@translate}<br><br>
+    	<li><label class="cluetip" title="{'UAM_mailexcTitle'|translate}|{'UAM_mailexcTitle_d'|translate}">{'UAM_MailExclusion'|@translate}</label><br><br>
+        <input type="radio" value="false" {$UAM_MAILEXCLUSION_FALSE} name="UAM_MailExclusion">{'UAM_MailExclusion_false'|@translate}<br>
+        <input type="radio" value="true" {$UAM_MAILEXCLUSION_TRUE} name="UAM_MailExclusion">{'UAM_MailExclusion_true'|@translate}<br><br>
     	</li>
 
-{if $UserAdvManager_MAILEXCLUSION_TRUE}
-  {if $UserAdvManager_ERROR_REPORTS4}     
-      <div id="uam_leftmargin"><textarea name="UserAdvManager_MailExclusion_List" id="UserAdvManager_MailExclusion_List" rows="3" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UserAdvManager_MAILEXCLUSION_LIST}</textarea></div><br><br>
-  {else}
-      <div id="uam_leftmargin"><textarea name="UserAdvManager_MailExclusion_List" id="UserAdvManager_MailExclusion_List" rows="3" cols="80" {$TAG_INPUT_ENABLED}>{$UserAdvManager_MAILEXCLUSION_LIST}</textarea></div><br><br>
-  {/if}
-{else}
-      <div id="uam_leftmargin"><textarea name="UserAdvManager_MailExclusion_List" id="UserAdvManager_MailExclusion_List" rows="3" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UserAdvManager_MAILEXCLUSION_LIST}</textarea></div><br><br>
+{if $UAM_MAILEXCLUSION_TRUE}
+  {if $UAM_ERROR_REPORTS4}     
+      <div id="uam_leftmargin"><textarea name="UAM_MailExclusion_List" id="UAM_MailExclusion_List" rows="3" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UAM_MAILEXCLUSION_LIST}</textarea></div><br><br>
+  {else}
+      <div id="uam_leftmargin"><textarea name="UAM_MailExclusion_List" id="UAM_MailExclusion_List" rows="3" cols="80" {$TAG_INPUT_ENABLED}>{$UAM_MAILEXCLUSION_LIST}</textarea></div><br><br>
+  {/if}
+{else}
+      <div id="uam_leftmargin"><textarea name="UAM_MailExclusion_List" id="UAM_MailExclusion_List" rows="3" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UAM_MAILEXCLUSION_LIST}</textarea></div><br><br>
 {/if}
     </ul>
@@ -97,5 +97,5 @@
     
   <div id="config2_header" class="instructionBlockHeaderCollapsed" onclick="nbc_blockToggleDisplay('config2_header', 'Config2')">
-    <span class="cluetip" title="{'UAM_confirmTitle'|translate}|{'UAM_confirmTitle_d'|translate}">{'UserAdvManager_Title2'|@translate}</span>
+    <span class="cluetip" title="{'UAM_confirmTitle'|translate}|{'UAM_confirmTitle_d'|translate}">{'UAM_Title2'|@translate}</span>
   </div>
   
@@ -103,58 +103,58 @@
     <fieldset>
       <ul>
-      	<li><label class="cluetip" title="{'UAM_infomailTitle'|translate}|{'UAM_infomailTitle_d'|translate}">{'UserAdvManager_Mail_Info'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_MAIL_INFO_FALSE} name="UserAdvManager_Mail_Info">{'UserAdvManager_Mail_Info_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_MAIL_INFO_TRUE} name="UserAdvManager_Mail_Info">{'UserAdvManager_Mail_Info_true'|@translate}<br><br>
+      	<li><label class="cluetip" title="{'UAM_infomailTitle'|translate}|{'UAM_infomailTitle_d'|translate}">{'UAM_Mail_Info'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_MAIL_INFO_FALSE} name="UAM_Mail_Info">{'UAM_Mail_Info_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_MAIL_INFO_TRUE} name="UAM_Mail_Info">{'UAM_Mail_Info_true'|@translate}<br><br>
       	</li>
         <ul>
-{if $UserAdvManager_MAIL_INFO_TRUE}
-  {if $UserAdvManager_ERROR_REPORTS1}      
-          <li><label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">{'UserAdvManager_MailInfo_Text'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_MailInfo_Text" id="UserAdvManager_MailInfo_Text" rows="10" cols="80" style="color: red"  {$TAG_INPUT_ENABLED}>{$UserAdvManager_MAILINFO_TEXT}</textarea><br><br>
-          </li>
-  {else}
-          <li><label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">{'UserAdvManager_MailInfo_Text'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_MailInfo_Text" id="UserAdvManager_MailInfo_Text" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UserAdvManager_MAILINFO_TEXT}</textarea><br><br>
-          </li>
-  {/if}
-{else}
-          <li><label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">{'UserAdvManager_MailInfo_Text'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_MailInfo_Text" id="UserAdvManager_MailInfo_Text" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UserAdvManager_MAILINFO_TEXT}</textarea><br><br>
-          </li>
-{/if}
-<!--
-{if 'FCK_PATH'|@defined}
-  <div style="text-align:right;">
-    <a href="#" onClick="toogleEditor('UserAdvManager_MailInfo_Text'); return false;">FCK Editor On/Off</a>
-  </div>
-{/if}
--->
-        </ul>
-
-      	<li><label class="cluetip" title="{'UAM_confirmmailTitle'|translate}|{'UAM_confirmmailTitle_d'|translate}">{'UserAdvManager_Confirm_Mail'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_CONFIRM_MAIL_FALSE} name="UserAdvManager_Confirm_Mail">{'UserAdvManager_Confirm_Mail_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_CONFIRM_MAIL_TRUE} name="UserAdvManager_Confirm_Mail">{'UserAdvManager_Confirm_Mail_true'|@translate}<br><br>
+{if $UAM_MAIL_INFO_TRUE}
+  {if $UAM_ERROR_REPORTS1}      
+          <li><label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">{'UAM_MailInfo_Text'|@translate}</label><br><br>
+            <textarea name="UAM_MailInfo_Text" id="UAM_MailInfo_Text" rows="10" cols="80" style="color: red"  {$TAG_INPUT_ENABLED}>{$UAM_MAILINFO_TEXT}</textarea><br><br>
+          </li>
+  {else}
+          <li><label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">{'UAM_MailInfo_Text'|@translate}</label><br><br>
+            <textarea name="UAM_MailInfo_Text" id="UAM_MailInfo_Text" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UAM_MAILINFO_TEXT}</textarea><br><br>
+          </li>
+  {/if}
+{else}
+          <li><label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">{'UAM_MailInfo_Text'|@translate}</label><br><br>
+            <textarea name="UAM_MailInfo_Text" id="UAM_MailInfo_Text" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UAM_MAILINFO_TEXT}</textarea><br><br>
+          </li>
+{/if}
+<!--
+{if 'FCK_PATH'|@defined}
+  <div style="text-align:right;">
+    <a href="#" onClick="toogleEditor('UAM_MailInfo_Text'); return false;">FCK Editor On/Off</a>
+  </div>
+{/if}
+-->
+        </ul>
+
+      	<li><label class="cluetip" title="{'UAM_confirmmailTitle'|translate}|{'UAM_confirmmailTitle_d'|translate}">{'UAM_Confirm_Mail'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_CONFIRM_MAIL_FALSE} name="UAM_Confirm_Mail">{'UAM_Confirm_Mail_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_CONFIRM_MAIL_TRUE} name="UAM_Confirm_Mail">{'UAM_Confirm_Mail_true'|@translate}<br><br>
       	</li>
 
         <ul>
-{if $UserAdvManager_CONFIRM_MAIL_TRUE}
-  {if $UserAdvManager_ERROR_REPORTS2}     
-          <li><label class="cluetip" title="{'UAM_confirmtxtTitle'|translate}|{'UAM_confirmtxtTitle_d'|translate}">{'UserAdvManager_ConfirmMail_Text'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_ConfirmMail_Text" id="UserAdvManager_ConfirmMail_Text" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_TEXT}</textarea><br><br>
-          </li>
-  {else}
-          <li><label class="cluetip" title="{'UAM_confirmtxtTitle'|translate}|{'UAM_confirmtxtTitle_d'|translate}">{'UserAdvManager_ConfirmMail_Text'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_ConfirmMail_Text" id="UserAdvManager_ConfirmMail_Text" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_TEXT}</textarea><br><br>
-          </li>
-  {/if}
-{else}
-          <li><label class="cluetip" title="{'UAM_confirmtxtTitle'|translate}|{'UAM_confirmtxtTitle_d'|translate}">{'UserAdvManager_ConfirmMail_Text'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_ConfirmMail_Text" id="UserAdvManager_ConfirmMail_Text" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_TEXT}</textarea><br><br>
-          </li>
-{/if}
-<!--
-{if 'FCK_PATH'|@defined}
-  <div style="text-align:right;">
-    <a href="#" onClick="toogleEditor('UserAdvManager_ConfirmMail_Text'); return false;">FCK Editor On/Off</a>
+{if $UAM_CONFIRM_MAIL_TRUE}
+  {if $UAM_ERROR_REPORTS2}     
+          <li><label class="cluetip" title="{'UAM_confirmtxtTitle'|translate}|{'UAM_confirmtxtTitle_d'|translate}">{'UAM_ConfirmMail_Text'|@translate}</label><br><br>
+            <textarea name="UAM_ConfirmMail_Text" id="UAM_ConfirmMail_Text" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_TEXT}</textarea><br><br>
+          </li>
+  {else}
+          <li><label class="cluetip" title="{'UAM_confirmtxtTitle'|translate}|{'UAM_confirmtxtTitle_d'|translate}">{'UAM_ConfirmMail_Text'|@translate}</label><br><br>
+            <textarea name="UAM_ConfirmMail_Text" id="UAM_ConfirmMail_Text" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_TEXT}</textarea><br><br>
+          </li>
+  {/if}
+{else}
+          <li><label class="cluetip" title="{'UAM_confirmtxtTitle'|translate}|{'UAM_confirmtxtTitle_d'|translate}">{'UAM_ConfirmMail_Text'|@translate}</label><br><br>
+            <textarea name="UAM_ConfirmMail_Text" id="UAM_ConfirmMail_Text" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_TEXT}</textarea><br><br>
+          </li>
+{/if}
+<!--
+{if 'FCK_PATH'|@defined}
+  <div style="text-align:right;">
+    <a href="#" onClick="toogleEditor('UAM_ConfirmMail_Text'); return false;">FCK Editor On/Off</a>
   </div>
 {/if}
@@ -164,33 +164,33 @@
         <br><hr><br>
         
-        <div id="uam_notice">{'UserAdvManager_Confirm_grpstat_notice'|@translate}</div>
+        <div id="uam_notice">{'UAM_Confirm_grpstat_notice'|@translate}</div>
         
         <br>
         
         <li>
-          <label class="cluetip" title="{'UAM_confirmgrpTitle'|translate}|{'UAM_confirmgrpTitle_d'|translate}">{'UserAdvManager_Confirm_Group'|@translate}</label><br><br>
-        </li>
-
-        <ul>
-          <li><label>{'UserAdvManager_No_Confirm_Group'|@translate}</label><br>
-            <div id="uam_leftmargin">{html_options name="UserAdvManager_No_Confirm_Group" options=$No_Confirm_Group.group_options selected=$No_Confirm_Group.group_selected}</div><br><br>
+          <label class="cluetip" title="{'UAM_confirmgrpTitle'|translate}|{'UAM_confirmgrpTitle_d'|translate}">{'UAM_Confirm_Group'|@translate}</label><br><br>
+        </li>
+
+        <ul>
+          <li><label>{'UAM_No_Confirm_Group'|@translate}</label><br>
+            <div id="uam_leftmargin">{html_options name="UAM_No_Confirm_Group" options=$No_Confirm_Group.group_options selected=$No_Confirm_Group.group_selected}</div><br><br>
           </li>
       
-          <li><label>{'UserAdvManager_Validated_Group'|@translate}</label><br>
-            <div id="uam_leftmargin">{html_options name="UserAdvManager_Validated_Group" options=$Validated_Group.group_options selected=$Validated_Group.group_selected}</div><br><br>
+          <li><label>{'UAM_Validated_Group'|@translate}</label><br>
+            <div id="uam_leftmargin">{html_options name="UAM_Validated_Group" options=$Validated_Group.group_options selected=$Validated_Group.group_selected}</div><br><br>
           </li>
         </ul>
 
         <li>
-          <label class="cluetip" title="{'UAM_confirmstatTitle'|translate}|{'UAM_confirmstatTitle_d'|translate}">{'UserAdvManager_Confirm_Status'|@translate}</label><br><br>
-        </li>
-
-        <ul>
-          <li><label>{'UserAdvManager_No_Confirm_Status'|@translate}</label><br>
-            <div id="uam_leftmargin">{html_options name="UserAdvManager_No_Confirm_Status" options=$No_Confirm_Status.Status_options selected=$No_Confirm_Status.Status_selected}</div><br><br>
-          </li>
-
-          <li><label>{'UserAdvManager_Validated_Status'|@translate}</label><br>
-            <div id="uam_leftmargin">{html_options name="UserAdvManager_Validated_Status" options=$Confirm_Status.Status_options selected=$Confirm_Status.Status_selected}</div><br><br>
+          <label class="cluetip" title="{'UAM_confirmstatTitle'|translate}|{'UAM_confirmstatTitle_d'|translate}">{'UAM_Confirm_Status'|@translate}</label><br><br>
+        </li>
+
+        <ul>
+          <li><label>{'UAM_No_Confirm_Status'|@translate}</label><br>
+            <div id="uam_leftmargin">{html_options name="UAM_No_Confirm_Status" options=$No_Confirm_Status.Status_options selected=$No_Confirm_Status.Status_selected}</div><br><br>
+          </li>
+
+          <li><label>{'UAM_Validated_Status'|@translate}</label><br>
+            <div id="uam_leftmargin">{html_options name="UAM_Validated_Status" options=$Confirm_Status.Status_options selected=$Confirm_Status.Status_selected}</div><br><br>
           </li>
         </ul>
@@ -198,57 +198,57 @@
         <br><hr><br>
 
-        <li><label class="cluetip" title="{'UAM_validationlimitTitle'|translate}|{'UAM_validationlimitTitle_d'|translate}">{'UserAdvManager_ValidationLimit_Info'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_CONFIRMMAIL_TIMEOUT_FALSE} name="UserAdvManager_ConfirmMail_TimeOut"> {'UserAdvManager_ConfirmMail_TimeOut_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_CONFIRMMAIL_TIMEOUT_TRUE} name="UserAdvManager_ConfirmMail_TimeOut"> {'UserAdvManager_ConfirmMail_TimeOut_true'|@translate}<input type="text" name="UserAdvManager_ConfirmMail_Delay" value="{$UserAdvManager_CONFIRMMAIL_DELAY}" size="5" style="text-align: center;"><br><br>
+        <li><label class="cluetip" title="{'UAM_validationlimitTitle'|translate}|{'UAM_validationlimitTitle_d'|translate}">{'UAM_ValidationLimit_Info'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_CONFIRMMAIL_TIMEOUT_FALSE} name="UAM_ConfirmMail_TimeOut"> {'UAM_ConfirmMail_TimeOut_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_CONFIRMMAIL_TIMEOUT_TRUE} name="UAM_ConfirmMail_TimeOut"> {'UAM_ConfirmMail_TimeOut_true'|@translate}<input type="text" name="UAM_ConfirmMail_Delay" value="{$UAM_CONFIRMMAIL_DELAY}" size="5" style="text-align: center;"><br><br>
         </li>
     
-        <li><label class="cluetip" title="{'UAM_remailTitle'|translate}|{'UAM_remailTitle_d'|translate}">{'UserAdvManager_ConfirmMail_Remail'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_CONFIRMMAIL_REMAIL_FALSE} name="UserAdvManager_ConfirmMail_Remail"> {'UserAdvManager_ConfirmMail_Remail_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_CONFIRMMAIL_REMAIL_TRUE} name="UserAdvManager_ConfirmMail_Remail"> {'UserAdvManager_ConfirmMail_Remail_true'|@translate}<br><br>
-        </li>
-
-        <ul>
-{if $UserAdvManager_CONFIRMMAIL_REMAIL_TRUE}
-  {if $UserAdvManager_ERROR_REPORTS1}
-        <li><label class="cluetip" title="{'UAM_remailtxt1Title'|translate}|{'UAM_remailtxt1Title_d'|translate}">{'UserAdvManager_ConfirmMail_ReMail_Txt1'|@translate}</label><br><br>
-          <textarea name="UserAdvManager_ConfirmMail_ReMail_Txt1" id="UserAdvManager_ConfirmMail_ReMail_Txt1" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_REMAIL_TXT1}</textarea><br><br>
-        </li>
-  {else}
-        <li><label class="cluetip" title="{'UAM_remailtxt1Title'|translate}|{'UAM_remailtxt1Title_d'|translate}">{'UserAdvManager_ConfirmMail_ReMail_Txt1'|@translate}</label><br><br>
-          <textarea name="UserAdvManager_ConfirmMail_ReMail_Txt1" id="UserAdvManager_ConfirmMail_ReMail_Txt1" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_REMAIL_TXT1}</textarea><br><br>
-        </li>
-  {/if}
-{else}
-        <li><label class="cluetip" title="{'UAM_remailtxt1Title'|translate}|{'UAM_remailtxt1Title_d'|translate}">{'UserAdvManager_ConfirmMail_ReMail_Txt1'|@translate}</label><br><br>
-          <textarea  name="UserAdvManager_ConfirmMail_ReMail_Txt1" id="UserAdvManager_ConfirmMail_ReMail_Txt1" rows="10" cols="80" readonly{$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_REMAIL_TXT1}</textarea><br><br>
-        </li>
-{/if}
-<!--
-{if 'FCK_PATH'|@defined}
-  <div style="text-align:right;">
-    <a href="#" onClick="toogleEditor('UserAdvManager_ConfirmMail_ReMail_Txt1'); return false;">FCK Editor On/Off</a>
-  </div>
-{/if}
--->
-
-{if $UserAdvManager_CONFIRMMAIL_REMAIL_TRUE}
-  {if $UserAdvManager_ERROR_REPORTS2}
-        <li><label class="cluetip" title="{'UAM_remailtxt2Title'|translate}|{'UAM_remailtxt2Title_d'|translate}">{'UserAdvManager_ConfirmMail_ReMail_Txt2'|@translate}</label><br><br>
-          <textarea name="UserAdvManager_ConfirmMail_ReMail_Txt2" id="UserAdvManager_ConfirmMail_ReMail_Txt2" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_REMAIL_TXT2}</textarea><br>
+        <li><label class="cluetip" title="{'UAM_remailTitle'|translate}|{'UAM_remailTitle_d'|translate}">{'UAM_ConfirmMail_Remail'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_CONFIRMMAIL_REMAIL_FALSE} name="UAM_ConfirmMail_Remail"> {'UAM_ConfirmMail_Remail_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_CONFIRMMAIL_REMAIL_TRUE} name="UAM_ConfirmMail_Remail"> {'UAM_ConfirmMail_Remail_true'|@translate}<br><br>
+        </li>
+
+        <ul>
+{if $UAM_CONFIRMMAIL_REMAIL_TRUE}
+  {if $UAM_ERROR_REPORTS1}
+        <li><label class="cluetip" title="{'UAM_remailtxt1Title'|translate}|{'UAM_remailtxt1Title_d'|translate}">{'UAM_ConfirmMail_ReMail_Txt1'|@translate}</label><br><br>
+          <textarea name="UAM_ConfirmMail_ReMail_Txt1" id="UAM_ConfirmMail_ReMail_Txt1" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_REMAIL_TXT1}</textarea><br><br>
+        </li>
+  {else}
+        <li><label class="cluetip" title="{'UAM_remailtxt1Title'|translate}|{'UAM_remailtxt1Title_d'|translate}">{'UAM_ConfirmMail_ReMail_Txt1'|@translate}</label><br><br>
+          <textarea name="UAM_ConfirmMail_ReMail_Txt1" id="UAM_ConfirmMail_ReMail_Txt1" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_REMAIL_TXT1}</textarea><br><br>
+        </li>
+  {/if}
+{else}
+        <li><label class="cluetip" title="{'UAM_remailtxt1Title'|translate}|{'UAM_remailtxt1Title_d'|translate}">{'UAM_ConfirmMail_ReMail_Txt1'|@translate}</label><br><br>
+          <textarea  name="UAM_ConfirmMail_ReMail_Txt1" id="UAM_ConfirmMail_ReMail_Txt1" rows="10" cols="80" readonly{$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_REMAIL_TXT1}</textarea><br><br>
+        </li>
+{/if}
+<!--
+{if 'FCK_PATH'|@defined}
+  <div style="text-align:right;">
+    <a href="#" onClick="toogleEditor('UAM_ConfirmMail_ReMail_Txt1'); return false;">FCK Editor On/Off</a>
+  </div>
+{/if}
+-->
+
+{if $UAM_CONFIRMMAIL_REMAIL_TRUE}
+  {if $UAM_ERROR_REPORTS2}
+        <li><label class="cluetip" title="{'UAM_remailtxt2Title'|translate}|{'UAM_remailtxt2Title_d'|translate}">{'UAM_ConfirmMail_ReMail_Txt2'|@translate}</label><br><br>
+          <textarea name="UAM_ConfirmMail_ReMail_Txt2" id="UAM_ConfirmMail_ReMail_Txt2" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_REMAIL_TXT2}</textarea><br>
         </li>
   {else}		
-        <li><label class="cluetip" title="{'UAM_remailtxt2Title'|translate}|{'UAM_remailtxt2Title_d'|translate}">{'UserAdvManager_ConfirmMail_ReMail_Txt2'|@translate}</label><br><br>
-          <textarea name="UserAdvManager_ConfirmMail_ReMail_Txt2" id="UserAdvManager_ConfirmMail_ReMail_Txt2" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_REMAIL_TXT2}</textarea><br>
-        </li>
-  {/if}
-{else}
-        <li><label class="cluetip" title="{'UAM_remailtxt2Title'|translate}|{'UAM_remailtxt2Title_d'|translate}">{'UserAdvManager_ConfirmMail_ReMail_Txt2'|@translate}</label><br><br>
-          <textarea name="UserAdvManager_ConfirmMail_ReMail_Txt2" id="UserAdvManager_ConfirmMail_ReMail_Txt2" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UserAdvManager_CONFIRMMAIL_REMAIL_TXT2}</textarea><br><br>
-        </li>
-{/if}
-<!--
-{if 'FCK_PATH'|@defined}
-  <div style="text-align:right;">
-    <a href="#" onClick="toogleEditor('UserAdvManager_ConfirmMail_ReMail_Txt2'); return false;">FCK Editor On/Off</a>
+        <li><label class="cluetip" title="{'UAM_remailtxt2Title'|translate}|{'UAM_remailtxt2Title_d'|translate}">{'UAM_ConfirmMail_ReMail_Txt2'|@translate}</label><br><br>
+          <textarea name="UAM_ConfirmMail_ReMail_Txt2" id="UAM_ConfirmMail_ReMail_Txt2" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_REMAIL_TXT2}</textarea><br>
+        </li>
+  {/if}
+{else}
+        <li><label class="cluetip" title="{'UAM_remailtxt2Title'|translate}|{'UAM_remailtxt2Title_d'|translate}">{'UAM_ConfirmMail_ReMail_Txt2'|@translate}</label><br><br>
+          <textarea name="UAM_ConfirmMail_ReMail_Txt2" id="UAM_ConfirmMail_ReMail_Txt2" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UAM_CONFIRMMAIL_REMAIL_TXT2}</textarea><br><br>
+        </li>
+{/if}
+<!--
+{if 'FCK_PATH'|@defined}
+  <div style="text-align:right;">
+    <a href="#" onClick="toogleEditor('UAM_ConfirmMail_ReMail_Txt2'); return false;">FCK Editor On/Off</a>
   </div>
 {/if}
@@ -264,5 +264,5 @@
 
   <div id="config3_header" class="instructionBlockHeaderCollapsed" onclick="nbc_blockToggleDisplay('config3_header', 'Config3')">
-    <span class="cluetip" title="{'UAM_miscTitle'|translate}|{'UAM_miscTitle_d'|translate}">{'UserAdvManager_Title3'|@translate}</span>
+    <span class="cluetip" title="{'UAM_miscTitle'|translate}|{'UAM_miscTitle_d'|translate}">{'UAM_Title3'|@translate}</span>
   </div>
   
@@ -270,29 +270,29 @@
     <fieldset>
       <ul>
-        <li><label class="cluetip" title="{'UAM_ghosttrackerTitle'|translate}|{'UAM_ghosttrackerTitle_d'|translate}">{'UserAdvManager_GhostTracker'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_GHOSTRACKER_FALSE} name="UserAdvManager_GhostUser_Tracker">{'UserAdvManager_GhostTracker_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_GHOSTRACKER_TRUE} name="UserAdvManager_GhostUser_Tracker">{'UserAdvManager_GhostTracker_true'|@translate}<input type="text" name="UserAdvManager_GhostTracker_DayLimit" value="{$UserAdvManager_GHOSTRACKER_DAYLIMIT}" size="5" style="text-align: center;"><br><br>
+        <li><label class="cluetip" title="{'UAM_ghosttrackerTitle'|translate}|{'UAM_ghosttrackerTitle_d'|translate}">{'UAM_GhostTracker'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_GHOSTRACKER_FALSE} name="UAM_GhostUser_Tracker">{'UAM_GhostTracker_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_GHOSTRACKER_TRUE} name="UAM_GhostUser_Tracker">{'UAM_GhostTracker_true'|@translate}<input type="text" name="UAM_GhostTracker_DayLimit" value="{$UAM_GHOSTRACKER_DAYLIMIT}" size="5" style="text-align: center;"><br><br>
         </li>
         
         <ul>
-{if $UserAdvManager_GHOSTRACKER_TRUE}
-  {if $UserAdvManager_ERROR_REPORTS3}
-          <li><label class="cluetip" title="{'UAM_gttextTitle'|translate}|{'UAM_gttextTitle_d'|translate}">{'UserAdvManager_GhostTracker_ReminderText'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_GhostTracker_ReminderText" id="UserAdvManager_GhostTracker_ReminderText" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UserAdvManager_GHOSTRACKER_REMINDERTEXT}</textarea><br><br>
-          </li>
-  {else}
-          <li><label class="cluetip" title="{'UAM_gttextTitle'|translate}|{'UAM_gttextTitle_d'|translate}">{'UserAdvManager_GhostTracker_ReminderText'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_GhostTracker_ReminderText" id="UserAdvManager_GhostTracker_ReminderText" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UserAdvManager_GHOSTRACKER_REMINDERTEXT}</textarea><br><br>
-          </li>
-  {/if}
-{else}
-          <li><label class="cluetip" title="{'UAM_gttextTitle'|translate}|{'UAM_gttextTitle_d'|translate}">{'UserAdvManager_GhostTracker_ReminderText'|@translate}</label><br><br>
-            <textarea name="UserAdvManager_GhostTracker_ReminderText" id="UserAdvManager_GhostTracker_ReminderText" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UserAdvManager_GHOSTRACKER_REMINDERTEXT}</textarea><br><br>
-          </li>
-{/if}
-<!--
-{if 'FCK_PATH'|@defined}
-  <div style="text-align:right;">
-    <a href="#" onClick="toogleEditor('UserAdvManager_GhostTracker_ReminderText'); return false;">FCK Editor On/Off</a>
+{if $UAM_GHOSTRACKER_TRUE}
+  {if $UAM_ERROR_REPORTS3}
+          <li><label class="cluetip" title="{'UAM_gttextTitle'|translate}|{'UAM_gttextTitle_d'|translate}">{'UAM_GhostTracker_ReminderText'|@translate}</label><br><br>
+            <textarea name="UAM_GhostTracker_ReminderText" id="UAM_GhostTracker_ReminderText" rows="10" cols="80" style="color: red" {$TAG_INPUT_ENABLED}>{$UAM_GHOSTRACKER_REMINDERTEXT}</textarea><br><br>
+          </li>
+  {else}
+          <li><label class="cluetip" title="{'UAM_gttextTitle'|translate}|{'UAM_gttextTitle_d'|translate}">{'UAM_GhostTracker_ReminderText'|@translate}</label><br><br>
+            <textarea name="UAM_GhostTracker_ReminderText" id="UAM_GhostTracker_ReminderText" rows="10" cols="80" {$TAG_INPUT_ENABLED}>{$UAM_GHOSTRACKER_REMINDERTEXT}</textarea><br><br>
+          </li>
+  {/if}
+{else}
+          <li><label class="cluetip" title="{'UAM_gttextTitle'|translate}|{'UAM_gttextTitle_d'|translate}">{'UAM_GhostTracker_ReminderText'|@translate}</label><br><br>
+            <textarea name="UAM_GhostTracker_ReminderText" id="UAM_GhostTracker_ReminderText" rows="10" cols="80" readonly {$TAG_INPUT_ENABLED}>{$UAM_GHOSTRACKER_REMINDERTEXT}</textarea><br><br>
+          </li>
+{/if}
+<!--
+{if 'FCK_PATH'|@defined}
+  <div style="text-align:right;">
+    <a href="#" onClick="toogleEditor('UAM_GhostTracker_ReminderText'); return false;">FCK Editor On/Off</a>
   </div>
 {/if}
@@ -300,12 +300,12 @@
         </ul>
     
-        <li><label class="cluetip" title="{'UAM_lastvisitTitle'|translate}|{'UAM_lastvisitTitle_d'|translate}">{'UserAdvManager_LastVisit'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_ADDLASTVISIT_FALSE} name="UserAdvManager_Add_LastVisit_Column">{'UserAdvManager_LastVisit_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_ADDLASTVISIT_TRUE} name="UserAdvManager_Add_LastVisit_Column">{'UserAdvManager_LastVisit_true'|@translate}<br><br>
-        </li>
-
-        <li><label class="cluetip" title="{'UAM_commentTitle'|translate}|{'UAM_commentTitle_d'|translate}">{'UserAdvManager_No_Comment_Anonymous'|@translate}</label><br><br>
-          <input type="radio" value="false" {$UserAdvManager_NO_COMMENT_ANO_FALSE} name="UserAdvManager_No_Comment_Anonymous">{'UserAdvManager_No_Comment_Anonymous_false'|@translate}<br>
-          <input type="radio" value="true" {$UserAdvManager_NO_COMMENT_ANO_TRUE} name="UserAdvManager_No_Comment_Anonymous">{'UserAdvManager_No_Comment_Anonymous_true'|@translate}<br><br>
+        <li><label class="cluetip" title="{'UAM_lastvisitTitle'|translate}|{'UAM_lastvisitTitle_d'|translate}">{'UAM_LastVisit'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_ADDLASTVISIT_FALSE} name="UAM_Add_LastVisit_Column">{'UAM_LastVisit_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_ADDLASTVISIT_TRUE} name="UAM_Add_LastVisit_Column">{'UAM_LastVisit_true'|@translate}<br><br>
+        </li>
+
+        <li><label class="cluetip" title="{'UAM_commentTitle'|translate}|{'UAM_commentTitle_d'|translate}">{'UAM_No_Comment_Anonymous'|@translate}</label><br><br>
+          <input type="radio" value="false" {$UAM_NO_COMMENT_ANO_FALSE} name="UAM_No_Comment_Anonymous">{'UAM_No_Comment_Anonymous_false'|@translate}<br>
+          <input type="radio" value="true" {$UAM_NO_COMMENT_ANO_TRUE} name="UAM_No_Comment_Anonymous">{'UAM_No_Comment_Anonymous_true'|@translate}<br><br>
         </li>
       </ul>
@@ -319,5 +319,5 @@
     
   <div id="Tips_header" class="instructionBlockHeaderCollapsed" onclick="nbc_blockToggleDisplay('Tips_header', 'Tips')">
-    <span class="cluetip" title="{'UAM_tipsTitle'|translate}|{'UAM_tipsTitle_d'|translate}">{'UserAdvManager_Title4'|@translate}</span>
+    <span class="cluetip" title="{'UAM_tipsTitle'|translate}|{'UAM_tipsTitle_d'|translate}">{'UAM_Title4'|@translate}</span>
   </div>
   
@@ -325,9 +325,9 @@
     <fieldset>
       <div id="Tips1_header" class="instructionBlockHeaderCollapsed" onclick="nbc_blockToggleDisplay('Tips1_header', 'Tips1')">
-        <span>{'UserAdvManager_Tips1'|@translate}</span>
+        <span>{'UAM_Tips1'|@translate}</span>
       </div>
       <div id="Tips1" class="instructionBlockContent" style="display:none">
         <fieldset>
-          {'UserAdvManager_Tips1_txt'|@translate}
+          {'UAM_Tips1_txt'|@translate}
         </fieldset>
       </div>
Index: /extensions/NBC_UserAdvManager/trunk/admin/userlist.tpl
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/admin/userlist.tpl	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/admin/userlist.tpl	(revision 5056)
@@ -17,5 +17,5 @@
 </div>
 
-<form method="post" action="{$UserAdvManager_F_ACTION}" class="general">
+<form method="post" action="{$UAM_F_ACTION}" class="general">
   <fieldset>
   	<legend class="cluetip" title="{'UAM_userlistTitle'|translate}|{'UAM_userlistTitle_d'|translate}">{'UserList_Title'|@translate}</legend>
Index: /extensions/NBC_UserAdvManager/trunk/admin/usermanager.tpl
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/admin/usermanager.tpl	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/admin/usermanager.tpl	(revision 5056)
@@ -17,5 +17,5 @@
 </div>
 
-<form method="post" action="{$UserAdvManager_F_ACTION}" class="general">
+<form method="post" action="{$UAM_F_ACTION}" class="general">
   <fieldset>
   	<legend class="cluetip" title="{'UAM_usermanTitle'|translate}|{'UAM_usermanTitle_d'|translate}">{'UserManager_Title'|@translate}</legend>
Index: /extensions/NBC_UserAdvManager/trunk/include/functions.inc.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/include/functions.inc.php	(revision 5056)
+++ /extensions/NBC_UserAdvManager/trunk/include/functions.inc.php	(revision 5056)
@@ -0,0 +1,1201 @@
+<?php
+include_once (NBC_UAM_PATH.'include/constants.php');
+load_language('plugin.lang', NBC_UAM_PATH);
+
+/* Function called from main.inc.php to send validation email */
+function SendMail2User($typemail, $id, $username, $password, $email, $confirm)
+{
+  /* Only available for next Piwigo release (bug in switch_lang function) */
+  //global $conf;
+  
+  /* ****************************************************************** */
+  /* Delete this after new Piwigo release (bug in switch_lang function) */
+  global $conf, $user;
+  $save_user = $user; 
+  /* ****************************************************************** */
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  
+	include_once(PHPWG_ROOT_PATH.'include/functions_mail.inc.php');
+  
+	$infos1_perso = "";
+  $infos2_perso = "";
+
+/* We have to get the user's language in database */
+  $query ='
+SELECT user_id, language
+FROM '.USER_INFOS_TABLE.'
+WHERE user_id = '.$id.'
+;';
+  $data = mysql_fetch_assoc(pwg_query($query));
+
+/* Check if user is already registered (profile changing) - If not (new registration), language is set to current gallery language */
+  if (empty($data))
+  {
+/* And switch gallery to this language before using personalized and multilangual contents */
+    $language = pwg_get_session_var( 'lang_switch', $user['language'] );
+    switch_lang_to($language);
+  }
+  else
+  {
+/* And switch gallery to this language before using personalized and multilangual contents */
+    $language = $data['language']; /* Usefull for debugging */
+    switch_lang_to($data['language']);
+    load_language('plugin.lang', NBC_UAM_PATH);
+  }
+
+  switch($typemail)
+  {
+    case 1:
+      $subject = '['.$conf['gallery_title'].'] '.l10n_args(get_l10n_args('Add of %s', stripslashes($username)));
+      $password = $password <> '' ? $password : l10n('UAM_empty_pwd');
+      
+      if (isset($conf_UAM[10]) and $conf_UAM[10] <> '')
+      {
+        if (function_exists('get_user_language_desc'))
+        {
+          $infos1_perso = get_user_language_desc($conf_UAM[10])."\n\n";
+        }
+        else $infos1_perso = l10n($conf_UAM[10])."\n\n"; 
+      }
+      
+      break;
+      
+    case 2:
+      $subject = '['.$conf['gallery_title'].'] '.l10n_args(get_l10n_args('Update of %s', stripslashes($username)));
+      $password = $password <> '' ? $password : l10n('UAM_empty_pwd');
+
+      break;
+        
+    case 3:
+      $subject = '['.$conf['gallery_title'].'] '.l10n_args(get_l10n_args('Update of %s', stripslashes($username)));
+      $password = $password <> '' ? $password : l10n('UAM_no_update_pwd');
+
+      break;
+  }
+
+  if (isset($conf_UAM[0]) and $conf_UAM[0] == 'true')
+  {
+    $infos1 = array(
+      get_l10n_args('infos_mail %s', stripslashes($username)),
+      get_l10n_args('User: %s', stripslashes($username)),
+      get_l10n_args('Password: %s', $password),
+      get_l10n_args('Email: %s', $email),
+      get_l10n_args('', ''),
+    );
+  }
+
+
+  if ( isset($conf_UAM[2]) and $conf_UAM[2] == 'true' and $confirm)
+  {
+    $infos2 = array
+    (
+      get_l10n_args('Link: %s', AddConfirmMail($id, $email)),
+      get_l10n_args('', ''),
+    );
+
+    if (isset($conf_UAM[11]) and $conf_UAM[11] <> '')
+    {
+      if (function_exists('get_user_language_desc'))
+      {
+        $infos2_perso = get_user_language_desc($conf_UAM[11])."\n\n";
+      }
+      else $infos2_perso = l10n($conf_UAM[11])."\n\n";
+    }
+  }
+
+/* Sending the email with subject and contents */
+  pwg_mail($email, array(
+    'subject' => $subject,
+    'content' => (isset($infos1) ? $infos1_perso.l10n_args($infos1)."\n\n" : "").(isset($infos2) ? $infos2_perso.l10n_args($infos2)."\n\n" : "").get_absolute_root_url(),
+  ));
+
+/* ********************** */
+/* Email sending debugger */
+/* This is only to trace  */
+/* the send of emails for */
+/* debugging              */
+/* ********************** */
+//$content = (isset($infos1) ? $infos1_perso.l10n_args($infos1)."\n\n" : "").(isset($infos2) ? $infos2_perso.l10n_args($infos2)."\n\n" : "").get_absolute_root_url();   
+//MailLog($email,$subject,$content,$language);
+/* ********************** */
+
+/* Switching back to default language */
+  /* ****************************************************************** */
+  /* Delete this after new Piwigo release (bug in switch_lang function) */
+$user=$save_user ;
+  /* ****************************************************************** */
+switch_lang_back();
+}
+
+
+/* Function called from UAM_admin.php to resend validation email with or without new validation key */
+function ResendMail2User($typemail, $user_id, $username, $email, $confirm)
+{
+  /* Only available for next Piwigo release (bug in switch_lang function) */
+  //global $conf;
+  
+  /* ****************************************************************** */
+  /* Delete this after new Piwigo release (bug in switch_lang function) */
+  global $conf, $user;
+  $save_user = $user; 
+  /* ****************************************************************** */
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+
+  $conf_UAM_ConfirmMail = unserialize($conf['nbc_UserAdvManager_ConfirmMail']);
+  
+	include_once(PHPWG_ROOT_PATH.'include/functions_mail.inc.php');
+  
+	$infos1_perso = "";
+  $infos2_perso = "";
+  
+/* We have to get the user's language in database */
+  $query ='
+SELECT user_id, language
+FROM '.USER_INFOS_TABLE.'
+WHERE user_id = '.$user_id.'
+;';
+  $data = mysql_fetch_assoc(pwg_query($query));
+  $language = $data['language'];
+  
+/* And switch gallery to this language before using personalized and multilangual contents */
+  switch_lang_to($data['language']);
+   
+  load_language('plugin.lang', NBC_UAM_PATH);
+
+  switch($typemail)
+  {
+    case 1:
+      $subject = '['.$conf['gallery_title'].'] '.l10n_args(get_l10n_args('Reminder_with_key_of_%s', $username));
+      
+      if (isset($conf_UAM_ConfirmMail[2]) and $conf_UAM_ConfirmMail[2] <> '' and isset($conf_UAM_ConfirmMail[3]) and $conf_UAM_ConfirmMail[3] == 'true' and $confirm)
+      {
+        if (function_exists('get_user_language_desc'))
+        {
+          $infos1 = get_user_language_desc($conf_UAM_ConfirmMail[2])."\n\n";
+        }
+				else $infos1 = l10n($conf_UAM_ConfirmMail[2])."\n\n";
+
+        $infos2 = array
+        (
+          get_l10n_args('Link: %s', ResetConfirmMail($user_id)),
+          get_l10n_args('', ''),
+        );        
+			}
+
+/* Set reminder true */      
+      $query = "
+UPDATE ".USER_CONFIRM_MAIL_TABLE."
+SET reminder = 'true'
+WHERE user_id = '".$user_id."'
+;";
+      pwg_query($query);
+      
+		break;
+      
+    case 2:
+      $subject = '['.$conf['gallery_title'].'] '.l10n_args(get_l10n_args('Reminder_without_key_of_%s',$username));
+      
+      if (isset($conf_UAM_ConfirmMail[2]) and $conf_UAM_ConfirmMail[2] <> '' and isset($conf_UAM_ConfirmMail[3]) and $conf_UAM_ConfirmMail[3] == 'true' and !$confirm)
+      {
+        if (function_exists('get_user_language_desc'))
+        {
+          $infos1 = get_user_language_desc($conf_UAM_ConfirmMail[2])."\n\n";
+        }
+        else $infos1 = l10n($conf_UAM_ConfirmMail[2])."\n\n";
+      }
+      
+/* Set reminder true */      
+      $query = "
+UPDATE ".USER_CONFIRM_MAIL_TABLE."
+SET reminder = 'true'
+WHERE user_id = '".$user_id."'
+;";
+      pwg_query($query);
+      
+    break;
+	}
+  
+  pwg_mail($email, array(
+    'subject' => $subject,
+    'content' => ($infos1."\n\n").(isset($infos2) ? l10n_args($infos2)."\n\n" : "").get_absolute_root_url(),
+  ));
+
+/* ********************** */
+/* Email sending debugger */
+/* This is only to trace  */
+/* the send of emails for */
+/* debugging              */
+/* ********************** */
+//$content = ($infos1."\n\n").(isset($infos2) ? l10n_args($infos2)."\n\n" : "").get_absolute_root_url();
+//MailLog($email,$subject,$content,$language);
+/* ********************** */
+
+/* Switching back to default language */
+  /* ****************************************************************** */
+  /* Delete this after new Piwigo release (bug in switch_lang function) */
+$user=$save_user ;
+  /* ****************************************************************** */
+switch_lang_back();
+}
+
+
+/* Function called from UAM_admin.php to send a reminder mail for ghost users */
+function ghostreminder($user_id, $username, $email)
+{
+  /* Only available for next Piwigo release (bug in switch_lang function) */
+  //global $conf;
+  
+  /* ****************************************************************** */
+  /* Delete this after new Piwigo release (bug in switch_lang function) */
+  global $conf, $user;
+  $save_user = $user; 
+  /* ****************************************************************** */
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  
+	include_once(PHPWG_ROOT_PATH.'include/functions_mail.inc.php');
+  
+	$infos1_perso = "";
+
+/* We have to get the user's language in database */
+  $query ='
+SELECT user_id, language
+FROM '.USER_INFOS_TABLE.'
+WHERE user_id = '.$user_id.'
+;';
+  $data = mysql_fetch_assoc(pwg_query($query));
+  $language = $data['language'];
+
+/* And switch gallery to this language before using personalized and multilangual contents */
+  switch_lang_to($data['language']);
+   
+  load_language('plugin.lang', NBC_UAM_PATH);
+  
+  $subject = '['.$conf['gallery_title'].'] '.l10n_args(get_l10n_args('Ghost_reminder_of_%s', $username));     
+
+  if (isset($conf_UAM[19]) and $conf_UAM[19] <> '' and isset($conf_UAM[17]) and $conf_UAM[17] == 'true')
+  {
+    if (function_exists('get_user_language_desc'))
+    {
+      $infos1 = get_user_language_desc($conf_UAM[19])."\n\n";
+    }
+    else
+    {
+      $infos1 = l10n($conf_UAM[19])."\n\n";
+    }
+
+    resetlastvisit($user_id);
+  }
+
+  pwg_mail($email, array(
+    'subject' => $subject,
+    'content' => $infos1.get_absolute_root_url(),
+  ));
+
+/* ********************** */
+/* Email sending debugger */
+/* This is only to trace  */
+/* the send of emails for */
+/* debugging              */
+/* ********************** */
+//$content = get_user_language_desc($conf_UAM[19])."\n\n";  
+//MailLog($email,$subject,$content,$language);
+/* ********************** */
+
+/* Switching back to default language */
+  /* ****************************************************************** */
+  /* Delete this after new Piwigo release (bug in switch_lang function) */
+$user=$save_user ;
+  /* ****************************************************************** */
+switch_lang_back();
+}
+
+
+/* Function called from functions AddConfirmMail and ResetConfirmMail for validation key generation */
+function FindAvailableConfirmMailID()
+{
+  while (true)
+  {
+    $id = generate_key(16);
+    $query = "
+SELECT COUNT(*)
+  FROM ".USER_CONFIRM_MAIL_TABLE."
+WHERE id = '".$id."'
+;";
+    list($count) = mysql_fetch_row(pwg_query($query));
+
+    if ($count == 0)
+      return $id;
+  }
+}
+
+
+/* Function called from functions SendMail2User to process unvalidated users and generate validation key link */
+function AddConfirmMail($user_id, $email)
+{
+  global $conf;
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  $Confirm_Mail_ID = FindAvailableConfirmMailID();
+
+  list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+  
+  if (isset($Confirm_Mail_ID))
+  {
+    $query = "
+SELECT status
+  FROM ".USER_INFOS_TABLE."
+WHERE user_id = '".$user_id."'
+;";
+    list($status) = mysql_fetch_row(pwg_query($query));
+    
+    $query = "
+INSERT INTO ".USER_CONFIRM_MAIL_TABLE."
+  (id, user_id, mail_address, status, date_check)
+VALUES
+  ('".$Confirm_Mail_ID."', '".$user_id."', '".$email."', '".$status."', null)
+;";
+    pwg_query($query);
+
+    $query = "
+DELETE FROM ".USER_GROUP_TABLE."
+WHERE user_id = '".$user_id."'
+  AND (
+    group_id = '".$conf_UAM[3]."'
+  OR 
+    group_id = '".$conf_UAM[4]."'
+  )
+;";
+    pwg_query($query);
+
+    if (!is_admin() and $conf_UAM[9] <> -1)
+    {
+      $query = "
+UPDATE ".USER_INFOS_TABLE."
+SET status = '".$conf_UAM[9]."'
+WHERE user_id = '".$user_id."'
+;";
+      pwg_query($query);
+    }
+
+    if ( $conf_UAM[3] <> -1 )
+    {
+      $query = "
+INSERT INTO ".USER_GROUP_TABLE."
+  (user_id, group_id)
+VALUES
+  ('".$user_id."', '".$conf_UAM[3]."')
+;";
+      pwg_query($query);
+    }
+    
+    return get_absolute_root_url().NBC_UAM_PATH.'ConfirmMail.php?key='.$Confirm_Mail_ID;
+  }
+}
+
+
+/* Function called from UAM_admin.php to reset validation key */
+function ResetConfirmMail($user_id)
+{
+  global $conf;
+  
+  $Confirm_Mail_ID = FindAvailableConfirmMailID();
+
+  list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+  
+  if (isset($Confirm_Mail_ID))
+  { 
+    $query = "
+UPDATE ".USER_CONFIRM_MAIL_TABLE."
+SET id = '".$Confirm_Mail_ID."'
+WHERE user_id = '".$user_id."'
+;";
+    pwg_query($query);
+
+		$query = "
+UPDATE ".USER_INFOS_TABLE."
+SET registration_date = '".$dbnow."'
+WHERE user_id = '".$user_id."'
+;";
+		pwg_query($query);
+    
+    return get_absolute_root_url().NBC_UAM_PATH.'ConfirmMail.php?key='.$Confirm_Mail_ID;
+  }
+}
+
+
+/* Function called from function_UserAdvManager.inc.php to reset last visit date after sending a reminder */
+function resetlastvisit($user_id)
+{
+  global $conf;
+
+  list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+
+  $query = "
+UPDATE ".USER_LASTVISIT_TABLE."
+SET lastvisit = '".$dbnow."', reminder = 'true'
+WHERE user_id = '".$user_id."'
+;";
+  pwg_query($query);
+}
+
+
+/* Function called from main.inc.php - Triggered on user deletion */
+function DeleteConfirmMail($user_id)
+{
+  $query = "
+DELETE FROM ".USER_CONFIRM_MAIL_TABLE."
+WHERE user_id = '".$user_id."'
+;";
+  pwg_query($query);
+}
+
+/* Function called from main.inc.php - Triggered on user deletion */
+function DeleteLastVisit($user_id)
+{
+  $query = "
+DELETE FROM ".USER_LASTVISIT_TABLE."
+WHERE user_id = '".$user_id."'
+;";
+  pwg_query($query);
+}
+
+/* Function called from ConfirmMail.php to verify validation key used by user according time limit */
+function VerifyConfirmMail($id)
+{
+  global $conf;
+
+  include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
+  
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+
+  $conf_UAM_ConfirmMail = unserialize($conf['nbc_UserAdvManager_ConfirmMail']);
+
+  $query = "
+SELECT COUNT(*)
+FROM ".USER_CONFIRM_MAIL_TABLE."
+WHERE id = '".$id."'
+;";
+  list($count) = mysql_fetch_row(pwg_query($query));
+
+  if ($count == 1)
+  {
+    $query = "
+SELECT user_id, status, date_check
+FROM ".USER_CONFIRM_MAIL_TABLE."
+WHERE id = '".$id."'
+;";
+    $data = mysql_fetch_assoc(pwg_query($query));
+        
+    if (!empty($data) and isset($data['user_id']) and !isset($data['date_check']))
+    {
+      $query = "
+SELECT registration_date
+FROM ".USER_INFOS_TABLE."
+WHERE user_id = '".$data['user_id']."'
+;";
+      list($registration_date) = mysql_fetch_row(pwg_query($query));
+
+/*              Time limit process              */
+/* ****************** begin ******************* */  
+      if (!empty($registration_date))
+      {
+				// Verify Confirmmail with time limit ON
+				if (isset ($conf_UAM_ConfirmMail[1]))
+				{
+					// dates formating and compare
+					$today = date("d-m-Y"); // Get today's date
+					list($day, $month, $year) = explode('-', $today); // explode date of today						 
+ 					$daytimestamp = mktime(0, 0, 0, $month, $day, $year);// Generate UNIX timestamp
+	  		
+	  			list($regdate, $regtime) = explode(' ', $registration_date); // Explode date and time from registration date
+					list($regyear, $regmonth, $regday) = explode('-', $regdate); // Explode date from registration date
+					$regtimestamp = mktime(0, 0, 0, $regmonth, $regday, $regyear);// Generate UNIX timestamp
+			
+					$deltasecs = $daytimestamp - $regtimestamp;// Compare the 2 UNIX timestamps	
+					$deltadays = floor($deltasecs / 86400);// Convert result from seconds to days
+
+					// Condition with the value set for time limit
+					if ($deltadays <= $conf_UAM_ConfirmMail[1]) // If Nb of days is less than the limit set
+					{
+						list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+
+						$query = '
+UPDATE '.USER_CONFIRM_MAIL_TABLE.'
+SET date_check="'.$dbnow.'"
+WHERE id = "'.$id.'"
+;';
+						pwg_query($query);
+      
+						if ($conf_UAM[3] <> -1) // Delete user from unvalidated users group
+						{
+							$query = "
+DELETE FROM ".USER_GROUP_TABLE."
+WHERE user_id = '".$data['user_id']."'
+  AND group_id = '".$conf_UAM[3]."'
+;";
+							pwg_query($query);
+						}
+	    
+						if ($conf_UAM[4] <> -1) // Add user to validated users group 
+						{
+							$query = "
+INSERT INTO ".USER_GROUP_TABLE."
+  (user_id, group_id)
+VALUES
+  ('".$data['user_id']."', '".$conf_UAM[4]."')
+;";
+							pwg_query($query);
+						}
+
+						if (($conf_UAM[5] <> -1 or isset($data['status']))) // Change user's status
+						{
+							$query = "
+UPDATE ".USER_INFOS_TABLE."
+SET status = '".(isset($data['status']) ? $data['status'] : $conf_UAM[5])."'
+WHERE user_id = '".$data['user_id']."'
+;";
+							pwg_query($query);
+						}
+						// Refresh user's category cache
+						invalidate_user_cache();
+  
+						return true;
+					}
+					elseif ($deltadays > $conf_UAM_ConfirmMail[1]) // If timelimit exeeds
+					{
+						return false;
+					}
+				}
+				// Verify Confirmmail with time limit OFF
+				else
+				{
+					list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+
+					$query = '
+UPDATE '.USER_CONFIRM_MAIL_TABLE.'
+SET date_check="'.$dbnow.'"
+WHERE id = "'.$id.'"
+;';
+					pwg_query($query);
+      
+					if ($conf_UAM[3] <> -1)
+					{
+						$query = "
+DELETE FROM ".USER_GROUP_TABLE."
+WHERE user_id = '".$data['user_id']."'
+AND group_id = '".$conf_UAM[3]."'
+;";
+						pwg_query($query);
+					}
+    
+					if ($conf_UAM[4] <> -1)
+					{
+						$query = "
+DELETE FROM ".USER_GROUP_TABLE."
+WHERE user_id = '".$data['user_id']."'
+AND group_id = '".$conf_UAM[4]."'
+;";
+						pwg_query($query);
+
+						$query = "
+INSERT INTO ".USER_GROUP_TABLE."
+  (user_id, group_id)
+VALUES
+  ('".$data['user_id']."', '".$conf_UAM[4]."')
+;";
+						pwg_query($query);
+					}
+
+					if (($conf_UAM[5] <> -1 or isset($data['status'])))
+					{
+						$query = "
+UPDATE ".USER_INFOS_TABLE."
+SET status = '".(isset($data['status']) ? $data['status'] : $conf_UAM[5])."'
+WHERE user_id = '".$data['user_id']."'
+;";
+						pwg_query($query);
+					}
+					// Refresh user's category cache
+					invalidate_user_cache();
+  
+					return true;
+				}
+			}
+		}
+	}
+  else
+    return false;
+}
+
+/* Function called from UAM_admin.php to force users validation by admin */
+function ForceValidation($id)
+{
+  global $conf;
+
+  include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+        
+  $query = "
+SELECT COUNT(*)
+  FROM ".USER_CONFIRM_MAIL_TABLE."
+WHERE user_id = '".$id."'
+;";
+  list($count) = mysql_fetch_row(pwg_query($query));
+
+  if ($count == 1)
+  {
+    $query = "
+SELECT user_id, status, date_check
+  FROM ".USER_CONFIRM_MAIL_TABLE."
+WHERE user_id = '".$id."'
+;";
+    $data = mysql_fetch_assoc(pwg_query($query));
+
+    if (!empty($data) and isset($data['user_id']) and !isset($data['date_check']))
+    {      
+			list($dbnow) = mysql_fetch_row(pwg_query('SELECT NOW();'));
+
+			$query = "
+UPDATE ".USER_CONFIRM_MAIL_TABLE."
+SET date_check='".$dbnow."'
+WHERE user_id = '".$data['user_id']."'
+;";
+			pwg_query($query);
+	     
+			if ($conf_UAM[3] <> -1)
+			{
+				$query = "
+DELETE FROM ".USER_GROUP_TABLE."
+WHERE user_id = '".$data['user_id']."'
+  AND group_id = '".$conf_UAM[3]."'
+;";
+				pwg_query($query);
+			}
+  
+			if ($conf_UAM[4] <> -1)
+			{
+				$query = "
+DELETE FROM ".USER_GROUP_TABLE."
+WHERE user_id = '".$data['user_id']."'
+  AND group_id = '".$conf_UAM[4]."'
+				;";
+				pwg_query($query);
+	
+				$query = "
+INSERT INTO ".USER_GROUP_TABLE."
+  (user_id, group_id)
+VALUES
+  ('".$data['user_id']."', '".$conf_UAM[4]."')
+;";
+				pwg_query($query);
+			}
+
+			if (($conf_UAM[5] <> -1 or isset($data['status'])))
+			{
+				$query = "
+UPDATE ".USER_INFOS_TABLE."
+SET status = '".(isset($data['status']) ? $data['status'] : $conf_UAM[5])."'
+WHERE user_id = '".$data['user_id']."'
+;";
+				pwg_query($query);
+			}
+			// Refresh user's category cache
+			invalidate_user_cache();
+			return true;
+		}
+	}
+}
+
+/* Function called from main.inc.php - Get username case insensitive */
+function NotSensibleSearchUsername($username)
+{
+  global $conf;
+  
+  if (isset($username))
+  {
+    $query = "
+SELECT ".$conf['user_fields']['username']."
+FROM ".USERS_TABLE."
+WHERE LOWER(".stripslashes($conf['user_fields']['username']).") = '".strtolower($username)."'
+;";
+    $users = mysql_num_rows(pwg_query($query));
+    if ($users > 0)
+    {
+      return true;
+    }
+    else
+    {
+      return false;
+    }
+  }
+}
+
+
+/* Function called from main.inc.php - Check if username matches forbidden caracters */
+function ValidateUsername($login)
+{
+  global $conf;
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+
+  if (isset($login) and isset($conf_UAM[8]) and $conf_UAM[8] <> '')
+  {
+    $conf_nbc_CharExclusion = preg_split("/,/",$conf_UAM[8]);
+    for ($i = 0 ; $i < count($conf_nbc_CharExclusion) ; $i++)
+    {
+      $pattern = '/'.$conf_nbc_CharExclusion[$i].'/i';
+      if (preg_match($pattern, $login))
+      {
+        return true;
+      }
+    }
+  }
+  else
+  {
+    return false;
+  }
+}
+
+
+/* Function called from main.inc.php - Check if user's email is in excluded email providers list */
+/* Doesn't work on call - Must be copied in main.inc.php to work */
+function ValidateEmailProvider($email)
+{
+  global $conf;
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  
+	if (isset($email) and isset($conf_UAM[13]) and $conf_UAM[13] <> '')
+	{
+		//$ncsemail = strtolower($email);
+		$conf_nbc_MailExclusion = preg_split("/[\s,]+/",$conf_UAM[13]);
+		for ($i = 0 ; $i < count($conf_nbc_MailExclusion) ; $i++)
+		{
+			$pattern = '/'.$conf_nbc_MailExclusion[$i].'/i';
+			if (preg_match($pattern, $email))
+      {
+        		return true;
+      }
+		}
+	}
+  else
+  {
+    return false;
+  }
+}
+
+
+/* Function called from UserAdvManager.php - Get unvalidated users according time limit */
+function get_unvalid_user_list()
+{
+	global $conf, $page;
+          
+	/* Get ConfirmMail configuration */
+  $conf_UAM_ConfirmMail = unserialize($conf['nbc_UserAdvManager_ConfirmMail']);
+  /* Get UAM configuration */
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  
+  $users = array();
+
+	/* search users depending expiration date */
+  $query = '
+SELECT DISTINCT u.'.$conf['user_fields']['id'].' AS id,
+                u.'.$conf['user_fields']['username'].' AS username,
+                u.'.$conf['user_fields']['email'].' AS email,
+                ui.status,
+                ui.adviser,
+                ui.enabled_high,
+                ui.level,
+                ui.registration_date
+FROM '.USERS_TABLE.' AS u
+  INNER JOIN '.USER_INFOS_TABLE.' AS ui
+    ON u.'.$conf['user_fields']['id'].' = ui.user_id
+  LEFT JOIN '.USER_GROUP_TABLE.' AS ug
+    ON u.'.$conf['user_fields']['id'].' = ug.user_id
+WHERE u.'.$conf['user_fields']['id'].' >= 3
+  AND (TO_DAYS(NOW()) - TO_DAYS(ui.registration_date) >= "'.$conf_UAM_ConfirmMail[1].'"
+  OR TO_DAYS(NOW()) - TO_DAYS(ui.registration_date) < "'.$conf_UAM_ConfirmMail[1].'")';
+
+	if ($conf_UAM[3] <> '-1' and $conf_UAM[9] == '-1')
+  {
+    $query.= '
+  AND ug.group_id = '.$conf_UAM[3];
+  }
+  if ($conf_UAM[3] == '-1' and $conf_UAM[9] <> '-1')
+  {
+    $query.= '
+  AND ui.status = \''.$conf_UAM[9]."'";
+  }
+  if ($conf_UAM[3] <> '-1' and $conf_UAM[9] <> '-1')
+  {
+    $query.= '
+  AND ug.group_id = \''.$conf_UAM[3]."'";
+  }
+  $query.= '
+ORDER BY id ASC
+;';
+
+	$result = pwg_query($query);
+      
+  while ($row = mysql_fetch_assoc($result))
+  {
+  	$user = $row;
+    $user['groups'] = array();
+
+    array_push($users, $user);
+	}
+
+	/* add group lists */
+  $user_ids = array();
+  foreach ($users as $i => $user)
+  {
+  	$user_ids[$i] = $user['id'];
+	}
+	
+	$user_nums = array_flip($user_ids);
+
+  if (count($user_ids) > 0)
+  {
+  	$query = '
+SELECT user_id, group_id
+  FROM '.USER_GROUP_TABLE.'
+WHERE user_id IN ('.implode(',', $user_ids).')
+;';
+        
+		$result = pwg_query($query);
+        
+    while ($row = mysql_fetch_assoc($result))
+    {
+    	array_push(
+      	$users[$user_nums[$row['user_id']]]['groups'],
+        $row['group_id']
+			);
+		}
+	}
+
+	return $users;
+}
+
+
+/* Function called from UserAdvManager.php - Get ghost users */
+function get_ghost_user_list()
+{
+	global $conf, $page;
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+  
+  $users = array();
+
+	/* search users depending expiration date */
+  $query = '
+SELECT DISTINCT u.'.$conf['user_fields']['id'].' AS id,
+                u.'.$conf['user_fields']['username'].' AS username,
+                u.'.$conf['user_fields']['email'].' AS email,
+                lv.lastvisit,
+                lv.reminder
+FROM '.USERS_TABLE.' AS u
+  INNER JOIN '.USER_LASTVISIT_TABLE.' AS lv
+    ON u.'.$conf['user_fields']['id'].' = lv.user_id
+WHERE (TO_DAYS(NOW()) - TO_DAYS(lv.lastvisit) >= "'.$conf_UAM[18].'")
+ORDER BY id ASC;';
+
+	$result = pwg_query($query);
+      
+  while ($row = mysql_fetch_assoc($result))
+  {
+  	$user = $row;
+    $user['groups'] = array();
+
+    array_push($users, $user);
+	}
+
+	/* add group lists */
+  $user_ids = array();
+  foreach ($users as $i => $user)
+  {
+  	$user_ids[$i] = $user['id'];
+	}
+
+	return $users;
+}
+
+
+/* Function called from UserAdvManager.php - Get all users to display the number of days since their last visit */
+function get_user_list()
+{
+	global $conf, $page;
+  
+  $users = array();
+
+	/* search users depending expiration date */
+  $query = '
+SELECT DISTINCT u.'.$conf['user_fields']['id'].' AS id,
+                u.'.$conf['user_fields']['username'].' AS username,
+                u.'.$conf['user_fields']['email'].' AS email,
+                ug.lastvisit
+FROM '.USERS_TABLE.' AS u
+  INNER JOIN '.USER_LASTVISIT_TABLE.' AS ug
+    ON u.'.$conf['user_fields']['id'].' = ug.user_id
+WHERE u.'.$conf['user_fields']['id'].' >= 3
+ORDER BY lastvisit DESC
+;';
+
+	$result = pwg_query($query);
+      
+  while ($row = mysql_fetch_assoc($result))
+  {
+  	$user = $row;
+    $user['groups'] = array();
+
+    array_push($users, $user);
+	}
+
+	/* add group lists */
+  $user_ids = array();
+  foreach ($users as $i => $user)
+  {
+  	$user_ids[$i] = $user['id'];
+	}
+
+	return $users;
+}
+
+
+/* Function called from UserAdvManager.php - to determine who is expired or not and giving a different display color */
+function expiration($id)
+{
+	global $conf, $page;
+          
+	/* Get ConfirmMail configuration */
+  $conf_UAM_ConfirmMail = unserialize($conf['nbc_UserAdvManager_ConfirmMail']);
+          
+	/* Get UAM configuration */
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+	
+	$query = "
+SELECT registration_date
+  FROM ".USER_INFOS_TABLE."
+WHERE user_id = '".$id."'
+;";
+	list($registration_date) = mysql_fetch_row(pwg_query($query));
+
+/*              Time limit process              */
+/* ****************** begin ******************* */  
+	if (!empty($registration_date))
+  {
+		// dates formating and compare
+		$today = date("d-m-Y"); // Get today's date
+		list($day, $month, $year) = explode('-', $today); // explode date of today						 
+ 		$daytimestamp = mktime(0, 0, 0, $month, $day, $year);// Generate UNIX timestamp
+	  	
+	  list($regdate, $regtime) = explode(' ', $registration_date); // Explode date and time from registration date
+		list($regyear, $regmonth, $regday) = explode('-', $regdate); // Explode date from registration date
+		$regtimestamp = mktime(0, 0, 0, $regmonth, $regday, $regyear);// Generate UNIX timestamp
+			
+		$deltasecs = $daytimestamp - $regtimestamp;// Compare the 2 UNIX timestamps	
+		$deltadays = floor($deltasecs / 86400);// Convert result from seconds to days
+
+		// Condition with the value set for time limit
+		if ($deltadays <= $conf_UAM_ConfirmMail[1]) // If Nb of days is less than the limit set
+		{
+			return false;
+		}
+		else
+		{
+			return True;
+		}
+	}
+}
+
+
+/**
+ * Returns a password's score for password complexity check
+ *
+ * @param password filled by user
+ * 
+ * Thanx to MathieuGut from http://m-gut.developpez.com
+ */
+function testpassword($password) // Le mot de passe passé en paramètre - $password given by user
+{
+
+  // Initialisation des variables - Variables initiation
+  $points = 0;
+  $point_lowercase = 0;
+  $point_uppercase = 0;
+  $point_numbers = 0;
+  $point_characters = 0;
+
+  // On récupère la longueur du mot de passe - Getting password lengh	
+  $length = strlen($password);
+  
+  // On fait une boucle pour lire chaque lettre - Loop to read password characters
+  for($i = 0; $i < $length; $i++)
+  {
+    // On sélectionne une à une chaque lettre - Select each letters
+    // $i étant à 0 lors du premier passage de la boucle - $i is 0 at first turn
+    $letters = $password[$i];
+
+    if ($letters>='a' && $letters<='z')
+    {
+      // On ajoute 1 point pour une minuscule - Adding 1 point to score for a lowercase
+		  $points = $points + 1;
+
+		  // On rajoute le bonus pour une minuscule - Adding bonus points for lowercase
+		  $point_lowercase = 1;
+    }
+    else if ($letters>='A' && $letters <='Z')
+    {
+      // On ajoute 2 points pour une majuscule - Adding 2 points to score for uppercase
+      $points = $points + 2;
+		
+      // On rajoute le bonus pour une majuscule - Adding bonus points for uppercase
+      $point_uppercase = 2;
+    }
+    else if ($letters>='0' && $letters<='9')
+    {
+      // On ajoute 3 points pour un chiffre - Adding 3 points to score for numbers
+      $points = $points + 3;
+		
+      // On rajoute le bonus pour un chiffre - Adding bonus points for numbers
+      $point_numbers = 3;
+    }
+    else
+    {
+      // On ajoute 5 points pour un caractère autre - Adding 5 points to score for special characters
+      $points = $points + 5;
+		
+      // On rajoute le bonus pour un caractère autre - Adding bonus points for special characters
+      $point_characters = 5;
+    }
+  }
+
+  // Calcul du coefficient points/longueur - calculating the coefficient points/length
+  $step1 = $points / $length;
+
+  // Calcul du coefficient de la diversité des types de caractères... - Calculation of the diversity of character types...
+  $step2 = $point_lowercase + $point_uppercase + $point_numbers + $point_characters;
+
+  // Multiplication du coefficient de diversité avec celui de la longueur - Multiplying the coefficient of diversity with that of the length
+  $score = $step1 * $step2;
+
+  // Multiplication du résultat par la longueur de la chaîne - Multiplying the result by the length of the chain
+  $finalscore = $score * $length;
+
+  return $finalscore;
+}
+
+/* Function called from maintain.inc.php - to check if database upgrade is needed */
+function table_exist($table)
+{
+  $query = 'DESC '.$table.';';
+  return (bool)($res=mysql_query($query));
+}
+
+/* Email sending debugger function */
+function MailLog  ($to, $subject, $content, $language)
+{
+   $fo=fopen (NBC_UAM_PATH.'admin/maillog.txt','a') ;
+   fwrite($fo,"======================\n") ;
+   fwrite($fo,'le ' . date('D, d M Y H:i:s') . "\r\n");
+   fwrite($fo,$to . "\n" . $subject . "\r\n") ;
+   fwrite($fo, "\n" . $content . "\r\n") ;
+   fwrite($fo, 'Langue : '."\n" . $language . "\r\n") ;
+   fclose($fo) ;
+ //return mail ($to,$subject) ;
+}
+
+
+/* Function called from UAM_admin.php to get the plugin version */
+function PluginVer($dir)
+{
+  $path = $dir;
+
+  $plg_data = implode( '', file($path.'main.inc.php') );
+  if ( preg_match("|Plugin Name: (.*)|", $plg_data, $val) )
+  {
+    $plugin['name'] = trim( $val[1] );
+  }
+  if (preg_match("|Version: (.*)|", $plg_data, $val))
+  {
+    $plugin['version'] = trim($val[1]);
+  }
+  if ( preg_match("|Plugin URI: (.*)|", $plg_data, $val) )
+  {
+    $plugin['uri'] = trim($val[1]);
+  }
+  if ($desc = load_language('description.txt', $path.'/', array('return' => true)))
+  {
+    $plugin['description'] = trim($desc);
+  }
+  elseif ( preg_match("|Description: (.*)|", $plg_data, $val) )
+  {
+    $plugin['description'] = trim($val[1]);
+  }
+  if ( preg_match("|Author: (.*)|", $plg_data, $val) )
+  {
+    $plugin['author'] = trim($val[1]);
+  }
+  if ( preg_match("|Author URI: (.*)|", $plg_data, $val) )
+  {
+    $plugin['author uri'] = trim($val[1]);
+  }
+  if (!empty($plugin['uri']) and strpos($plugin['uri'] , 'extension_view.php?eid='))
+  {
+    list( , $extension) = explode('extension_view.php?eid=', $plugin['uri']);
+    if (is_numeric($extension)) $plugin['extension'] = $extension;
+  }
+// IMPORTANT SECURITY !
+  $plugin = array_map('htmlspecialchars', $plugin);
+
+  return $plugin ;
+}
+
+/* Funtion called in maintain.inc.php to clean obsolete files */
+function clean_obsolete_files($obsolete_file_list)
+{
+  if (!file_exists(NBC_UAM_PATH.$obsolete_file_list))
+  {
+    return TRUE;
+  }
+  $obsolete = file(NBC_UAM_PATH.$obsolete_file_list);
+  array_push($obsolete, $obsolete_file_list);
+  return clean_obsolete_list($obsolete);
+}
+
+function clean_obsolete_list($file_list = array(), &$errors = array())
+{
+  if (!function_exists('unlink'))
+  {
+      // No unlink available...
+      array_push($errors, l10n('uam_no_unlink'));
+      return FALSE;
+  }
+  $success = TRUE;
+  foreach ($file_list as $file)
+  {
+    $file = NBC_UAM_PATH . $file;
+  $to = '';
+  $subject ='';
+  $language = '';
+  MailLog  ($to, $subject, $file, $language);
+    //if (file_exists($file))
+    //{
+      // Remove obsolete file
+      $success &= unlink($file);
+  $to = '';
+  $subject ='';
+  $language = '';
+  MailLog  ($to, $subject, $file, $success);
+    //}
+  }
+  if (!$success)
+  {
+      array_push($errors, l10n('uam_unlink_errors'));
+  }
+  return $success;
+}
+?>
Index: /extensions/NBC_UserAdvManager/trunk/language/de_DE/plugin.lang.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/language/de_DE/plugin.lang.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/language/de_DE/plugin.lang.php	(revision 5056)
@@ -3,5 +3,5 @@
 global $lang,$conf;
 
-$conf_UserAdvManager = isset($conf['UserAdvManager']) ? explode(";" , $conf['UserAdvManager']) : array();
+$conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 
@@ -24,16 +24,16 @@
 
 /* Errors and Warnings */
-$lang['UserAdvManager_audit_ok'] = 'Audit OK';
+$lang['UAM_audit_ok'] = 'Audit OK';
 $lang['Err_audit_no_casse'] = '<b>Diese Konten sind identisch mit den Fall aufmerksam:</b> ';
 $lang['Err_audit_username_char'] = '<b>Dieses Konto verwendet eine oder mehrere der verbotenen Zeichen:</b> ';
 $lang['Err_audit_email_forbidden'] = '<b>Dieses Konto verwendet eine E-Mail-Anbieter sind untersagt:</b> ';
 $lang['Err_audit_advise'] = '<b>Sie müssen Korrekturen an mit neuen Regeln die Sie aktiviert haben, nachzukommen durchzuführen.<br>Verwenden Sie ein Datenbank-Management-Dienstprogramm, um Benutzer-Accounts direkt in der Tabelle richtig ###_USERS';
-$lang['UserAdvManager_Empty Author'] = 'Der Autor Feld müssen ausgefüllt werden um einen Kommentar zu schicken.';
-if ( isset($conf_UserAdvManager[1]) and $conf_UserAdvManager[1] == 'true' )
+$lang['UAM_Empty Author'] = 'Der Autor Feld müssen ausgefüllt werden um einen Kommentar zu schicken.';
+if ( isset($conf_UAM[1]) and $conf_UAM[1] == 'true' )
 	$lang['reg_err_login5'] = 'Benutzername bereits vorhanden, WARNUNG Name ist Groß-und Kleinschreibung.';
 $lang['reg_err_login6'] = 'Benutzername muss nicht die folgenden Zeichen übereinstimmen: ';
 $lang['reg_err_login7'] = 'Ihre E-Mail-Anbieter für die Registrierung ist verboten. Gebannten E-Mail-Anbieter sind: ';
-$lang['UserAdvManager_empty_pwd'] = '[leeren Passwort]';
-$lang['UserAdvManager_no_update_pwd'] = '[Profil aktualisiert ohne Passwort geändert]';
+$lang['UAM_empty_pwd'] = '[leeren Passwort]';
+$lang['UAM_no_update_pwd'] = '[Profil aktualisiert ohne Passwort geändert]';
 $lang['invalid_pwd'] = 'Ungültiger Benutzername oder Passwort !';
 $lang['No_validation_for_Guest'] = 'Der &quot;Gast&quot;-Konto ist nicht Gegenstand der Validierung';
@@ -72,5 +72,5 @@
 $lang['Reminder_Sent_NOK'] = 'NEIN';
 /* Errors and Warnings */
-$lang['UserAdvManager_save_config'] ='Konfiguration gespeichert.';
+$lang['UAM_save_config'] ='Konfiguration gespeichert.';
 $lang['reg_err_login3'] = 'Sicherheit: Das Passwort ist obligatorisch !';
 $lang['reg_err_login4_%s'] = 'Sicherheit: Ein Steuer-System berechnet eine Partitur von der gewählten Passwörter Komplexität. Die Komplexität des Passworts zu niedrig ist (score = %s). Bitte wählen Sie ein neues Passwort zu mehr Sicherheit, indem Sie folgende Regeln:<br>
@@ -123,63 +123,63 @@
 $lang['SubTitle1'] = 'Plugin-Konfiguration';
 $lang['Tab_Global'] = 'Konfiguration';
-$lang['UserAdvManager_Title1'] = 'Einstellen Einschränkungen für Registrierungen';
-$lang['UserAdvManager_Title2'] = 'Einstellen Bestätigungen und Validierungen der Registrierung';
-$lang['UserAdvManager_Title3'] = 'Einstellen der Registrierung durchgeführt und andere Optionen';
-$lang['UserAdvManager_Title4'] = 'Tipps und Beispiele für die Benutzung';
-$lang['UserAdvManager_No_Casse'] = 'Benutzernamen: Groß-und Kleinschreibung';
-$lang['UserAdvManager_No_Casse_true'] = ' Aktivieren';
-$lang['UserAdvManager_No_Casse_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_Username_Char'] = ' Benutzernamen: Ausschluss von Zeichen';
-$lang['UserAdvManager_Username_Char_true'] = ' Zeichen Verboten:<br>(Verwenden Sie ein Komma, um ein Zeichen getrennt)<br><br>';
-$lang['UserAdvManager_Username_Char_false'] = ' Erlauben Sie alle (Standard)';
-$lang['UserAdvManager_Password_Enforced'] = 'Stärkung des Sicherheitsniveaus von Kennwörtern';
-$lang['UserAdvManager_Password_Enforced_true'] = ' Aktivieren. Minimale Punktzahl: ';
-$lang['UserAdvManager_Password_Enforced_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_AdminPassword_Enforced'] = 'Die Anwendung für Administratoren';
-$lang['UserAdvManager_AdminPassword_Enforced_true'] = ' Aktivieren';
-$lang['UserAdvManager_AdminPassword_Enforced_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_PasswordTest'] = 'Passwort testen : ';
-$lang['UserAdvManager_ScoreTest'] = 'Ergebnis : ';
-$lang['UserAdvManager_MailExclusion'] = 'E-Mail-Domänen Ausgrenzung';
-$lang['UserAdvManager_MailExclusion_true'] = ' Schließen Sie die folgenden E-Mail-Domänen:<br>(Verwenden Sie ein Komma zu trennen jede Domain)';
-$lang['UserAdvManager_MailExclusion_false'] = ' Deaktivieren (Standard)';
-
-$lang['UserAdvManager_Mail_Info'] = 'Informationen E-Mail an Benutzer:';
-$lang['UserAdvManager_Mail_Info_true'] = ' Aktivieren';
-$lang['UserAdvManager_Mail_Info_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_MailInfo_Text'] = ' Anpassen der Informationen per E-Mail:';
-$lang['UserAdvManager_Confirm_Mail'] = 'Bestätigung der Anmeldung:';
-$lang['UserAdvManager_Confirm_Mail_true'] = ' Aktivieren';
-$lang['UserAdvManager_Confirm_Mail_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_ConfirmMail_Text'] = ' Anpassen der E-Mail-Bestätigung';
-$lang['UserAdvManager_Confirm_grpstat_notice'] = 'Achtung: Es ist ratsam, entweder die Gruppe oder die Validierung Satzung und nicht beide gleichzeitig.';
-$lang['UserAdvManager_Confirm_Group'] = 'Validation Gruppen<br>(verlassen ------- zum nicht zu beeinträchtigen Gruppe)';
-$lang['UserAdvManager_Confirm_Status'] = 'Validation Satzung<br>(verlassen ------- ein Versäumnis des Piwigo zu halten)';
-$lang['UserAdvManager_No_Confirm_Group'] = 'Gruppe für Benutzer, die nicht validiert ihrer Eintragung<br>';
-$lang['UserAdvManager_Validated_Group'] = 'Gruppe für Benutzer, die ihre Anmeldung bestätigt<br>';
-$lang['UserAdvManager_No_Confirm_Status'] = 'Status für Benutzer, die nicht validiert ihrer Eintragung<br>';
-$lang['UserAdvManager_Validated_Status'] = 'Status für Benutzer, die ihre Anmeldung bestätigt<br>';
-$lang['UserAdvManager_ValidationLimit_Info'] = 'Anmeldeschluss Validierung beschränkt';
-$lang['UserAdvManager_ConfirmMail_TimeOut_true'] = ' Aktivieren. Anzahl der Tage bis zum Ablauf: ';
-$lang['UserAdvManager_ConfirmMail_TimeOut_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_ConfirmMail_Remail'] = 'Erinnern Unvalidierte User';
-$lang['UserAdvManager_ConfirmMail_Remail_true'] = ' Aktivieren';
-$lang['UserAdvManager_ConfirmMail_Remail_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt1'] = 'Anpassen der Erinnerungs-Nachricht <b><u>mit</u></b> neue Regeneration der Schlüssel Validierung.';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt2'] = 'Anpassen der Erinnerungs-Nachricht <b><u>ohne</u></b> neue Regeneration der Schlüssel Validierung.';
-
-$lang['UserAdvManager_GhostTracker'] = 'Geist Besucher-Management (Geist Tracker)';
-$lang['UserAdvManager_GhostTracker_true'] = ' Aktivieren. Maximale Zeit in Tagen zwischen zwei Besuche: ';
-$lang['UserAdvManager_GhostTracker_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_GhostTracker_ReminderText'] = 'Anpassen der Geist Tracker Erinnerungs-Nachricht';
-$lang['UserAdvManager_LastVisit'] = ' Tracking registrierte Benutzer';
-$lang['UserAdvManager_LastVisit_true'] = ' Aktivieren';
-$lang['UserAdvManager_LastVisit_false'] = ' Deaktivieren (Standard)';
-$lang['UserAdvManager_No_Comment_Anonymous'] = 'Nickname obligatorisch für Gäste Kommentare';
-$lang['UserAdvManager_No_Comment_Anonymous_true'] = ' Aktivieren';
-$lang['UserAdvManager_No_Comment_Anonymous_false'] = ' Deaktivieren (Standard)';
-
-$lang['UserAdvManager_Tips1'] = 'Registrations with email validation and warning message on the Piwigo\'s homepage';
-$lang['UserAdvManager_Tips1_txt'] = '
+$lang['UAM_Title1'] = 'Einstellen Einschränkungen für Registrierungen';
+$lang['UAM_Title2'] = 'Einstellen Bestätigungen und Validierungen der Registrierung';
+$lang['UAM_Title3'] = 'Einstellen der Registrierung durchgeführt und andere Optionen';
+$lang['UAM_Title4'] = 'Tipps und Beispiele für die Benutzung';
+$lang['UAM_No_Casse'] = 'Benutzernamen: Groß-und Kleinschreibung';
+$lang['UAM_No_Casse_true'] = ' Aktivieren';
+$lang['UAM_No_Casse_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_Username_Char'] = ' Benutzernamen: Ausschluss von Zeichen';
+$lang['UAM_Username_Char_true'] = ' Zeichen Verboten:<br>(Verwenden Sie ein Komma, um ein Zeichen getrennt)<br><br>';
+$lang['UAM_Username_Char_false'] = ' Erlauben Sie alle (Standard)';
+$lang['UAM_Password_Enforced'] = 'Stärkung des Sicherheitsniveaus von Kennwörtern';
+$lang['UAM_Password_Enforced_true'] = ' Aktivieren. Minimale Punktzahl: ';
+$lang['UAM_Password_Enforced_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_AdminPassword_Enforced'] = 'Die Anwendung für Administratoren';
+$lang['UAM_AdminPassword_Enforced_true'] = ' Aktivieren';
+$lang['UAM_AdminPassword_Enforced_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_PasswordTest'] = 'Passwort testen : ';
+$lang['UAM_ScoreTest'] = 'Ergebnis : ';
+$lang['UAM_MailExclusion'] = 'E-Mail-Domänen Ausgrenzung';
+$lang['UAM_MailExclusion_true'] = ' Schließen Sie die folgenden E-Mail-Domänen:<br>(Verwenden Sie ein Komma zu trennen jede Domain)';
+$lang['UAM_MailExclusion_false'] = ' Deaktivieren (Standard)';
+
+$lang['UAM_Mail_Info'] = 'Informationen E-Mail an Benutzer:';
+$lang['UAM_Mail_Info_true'] = ' Aktivieren';
+$lang['UAM_Mail_Info_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_MailInfo_Text'] = ' Anpassen der Informationen per E-Mail:';
+$lang['UAM_Confirm_Mail'] = 'Bestätigung der Anmeldung:';
+$lang['UAM_Confirm_Mail_true'] = ' Aktivieren';
+$lang['UAM_Confirm_Mail_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_ConfirmMail_Text'] = ' Anpassen der E-Mail-Bestätigung';
+$lang['UAM_Confirm_grpstat_notice'] = 'Achtung: Es ist ratsam, entweder die Gruppe oder die Validierung Satzung und nicht beide gleichzeitig.';
+$lang['UAM_Confirm_Group'] = 'Validation Gruppen<br>(verlassen ------- zum nicht zu beeinträchtigen Gruppe)';
+$lang['UAM_Confirm_Status'] = 'Validation Satzung<br>(verlassen ------- ein Versäumnis des Piwigo zu halten)';
+$lang['UAM_No_Confirm_Group'] = 'Gruppe für Benutzer, die nicht validiert ihrer Eintragung<br>';
+$lang['UAM_Validated_Group'] = 'Gruppe für Benutzer, die ihre Anmeldung bestätigt<br>';
+$lang['UAM_No_Confirm_Status'] = 'Status für Benutzer, die nicht validiert ihrer Eintragung<br>';
+$lang['UAM_Validated_Status'] = 'Status für Benutzer, die ihre Anmeldung bestätigt<br>';
+$lang['UAM_ValidationLimit_Info'] = 'Anmeldeschluss Validierung beschränkt';
+$lang['UAM_ConfirmMail_TimeOut_true'] = ' Aktivieren. Anzahl der Tage bis zum Ablauf: ';
+$lang['UAM_ConfirmMail_TimeOut_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_ConfirmMail_Remail'] = 'Erinnern Unvalidierte User';
+$lang['UAM_ConfirmMail_Remail_true'] = ' Aktivieren';
+$lang['UAM_ConfirmMail_Remail_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Anpassen der Erinnerungs-Nachricht <b><u>mit</u></b> neue Regeneration der Schlüssel Validierung.';
+$lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Anpassen der Erinnerungs-Nachricht <b><u>ohne</u></b> neue Regeneration der Schlüssel Validierung.';
+
+$lang['UAM_GhostTracker'] = 'Geist Besucher-Management (Geist Tracker)';
+$lang['UAM_GhostTracker_true'] = ' Aktivieren. Maximale Zeit in Tagen zwischen zwei Besuche: ';
+$lang['UAM_GhostTracker_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_GhostTracker_ReminderText'] = 'Anpassen der Geist Tracker Erinnerungs-Nachricht';
+$lang['UAM_LastVisit'] = ' Tracking registrierte Benutzer';
+$lang['UAM_LastVisit_true'] = ' Aktivieren';
+$lang['UAM_LastVisit_false'] = ' Deaktivieren (Standard)';
+$lang['UAM_No_Comment_Anonymous'] = 'Nickname obligatorisch für Gäste Kommentare';
+$lang['UAM_No_Comment_Anonymous_true'] = ' Aktivieren';
+$lang['UAM_No_Comment_Anonymous_false'] = ' Deaktivieren (Standard)';
+
+$lang['UAM_Tips1'] = 'Registrations with email validation and warning message on the Piwigo\'s homepage';
+$lang['UAM_Tips1_txt'] = '
           <ul>
             <li>
@@ -245,5 +245,5 @@
 $lang['GT_Init'] = 'Initializing Ghost Tracker';
 $lang['GhostTracker_Title'] = 'Geist Besucher-Management';
-$lang['UserAdvManager_GhostTracker_Init'] = 'Wenn Sie diese Funktion zum ersten Mal oder haben Sie nach einem langen Zeitraum aus, in dem neue Besucher registriert sind, müssen Sie initialisieren, oder setzen Sie den Geist Tracker reaktiviert. Dieser Vorgang ist nur nach Aktivierung oder Reaktivierung von der Möglichkeit gemacht. Bitte klicken Sie <u>einmal</u> die Reset-Taste unten.';
+$lang['UAM_GhostTracker_Init'] = 'Wenn Sie diese Funktion zum ersten Mal oder haben Sie nach einem langen Zeitraum aus, in dem neue Besucher registriert sind, müssen Sie initialisieren, oder setzen Sie den Geist Tracker reaktiviert. Dieser Vorgang ist nur nach Aktivierung oder Reaktivierung von der Möglichkeit gemacht. Bitte klicken Sie <u>einmal</u> die Reset-Taste unten.';
 /* UserList Tab */
 $lang['SubTitle5'] = 'Tracking-Besucher';
Index: /extensions/NBC_UserAdvManager/trunk/language/en_UK/plugin.lang.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/language/en_UK/plugin.lang.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/language/en_UK/plugin.lang.php	(revision 5056)
@@ -3,5 +3,5 @@
 global $lang,$conf;
 
-$conf_UserAdvManager = isset($conf['UserAdvManager']) ? explode(";" , $conf['UserAdvManager']) : array();
+$conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 
@@ -24,16 +24,16 @@
 
 /* Errors and Warnings */
-$lang['UserAdvManager_audit_ok'] = 'Audit OK';
+$lang['UAM_audit_ok'] = 'Audit OK';
 $lang['Err_audit_no_casse'] = '<b>These accounts are identical to the case closely :</b> ';
 $lang['Err_audit_username_char'] = '<b>This account uses one or more forbidden characters :</b> ';
 $lang['Err_audit_email_forbidden'] = '<b>This account uses a forbidden email provider :</b> ';
 $lang['Err_audit_advise'] = '<b>you have to perform corrections to comply with new rules that you have activated.<br>Use a database management utility to correct user accounts directly in the table ###_USERS';
-$lang['UserAdvManager_Empty Author'] = 'The author field have to be filled to send a comment.';
-if ( isset($conf_UserAdvManager[1]) and $conf_UserAdvManager[1] == 'true' )
+$lang['UAM_Empty Author'] = 'The author field have to be filled to send a comment.';
+if ( isset($conf_UAM[1]) and $conf_UAM[1] == 'true' )
 	$lang['reg_err_login5'] = 'Username already exist, WARNING name is case insensitive (Shift = Tiny).';
 $lang['reg_err_login6'] = 'Username does not have to match the following characters: ';
 $lang['reg_err_login7'] = 'Your email provider is banned for registration. Banned email providers are: ';
-$lang['UserAdvManager_empty_pwd'] = '[empty password]';
-$lang['UserAdvManager_no_update_pwd'] = '[profile updated without password changed]';
+$lang['UAM_empty_pwd'] = '[empty password]';
+$lang['UAM_no_update_pwd'] = '[profile updated without password changed]';
 $lang['invalid_pwd'] = 'Invalid username or password !';
 $lang['No_validation_for_Guest'] = 'The "Guest" account is not subject to validation';
@@ -72,5 +72,5 @@
 $lang['Reminder_Sent_NOK'] = 'NO';
 /* Errors and Warnings */
-$lang['UserAdvManager_save_config'] ='Configuration saved.';
+$lang['UAM_save_config'] ='Configuration saved.';
 $lang['reg_err_login3'] = 'Security : Password is mandatory !';
 $lang['reg_err_login4_%s'] = 'Security : A control system calculates a score on the chosen passwords complexity. The complexity of your password is too low (score = %s). Please, choose a new password more secure by following these rules:<br>
@@ -123,63 +123,63 @@
 $lang['SubTitle1'] = 'Plugin configuration';
 $lang['Tab_Global'] = 'Configuration';
-$lang['UserAdvManager_Title1'] = 'Setting restrictions for registrations';
-$lang['UserAdvManager_Title2'] = 'Setting confirmations and validations of registration';
-$lang['UserAdvManager_Title3'] = 'Setting the followed registrations and other options';
-$lang['UserAdvManager_Title4'] = 'Tips and examples of use';
-$lang['UserAdvManager_No_Casse'] = 'Usernames: Case sensitivity';
-$lang['UserAdvManager_No_Casse_true'] = ' Enable';
-$lang['UserAdvManager_No_Casse_false'] = ' Disable (default)';
-$lang['UserAdvManager_Username_Char'] = 'Usernames: Exclusion of characters';
-$lang['UserAdvManager_Username_Char_true'] = ' Banning characters:<br>(Use a comma to separate each character)<br><br>';
-$lang['UserAdvManager_Username_Char_false'] = ' Permit all (default)';
-$lang['UserAdvManager_Password_Enforced'] = 'Strengthening the security level of passwords';
-$lang['UserAdvManager_Password_Enforced_true'] = ' Enable. Minimum Score: ';
-$lang['UserAdvManager_Password_Enforced_false'] = ' Disable (default)';
-$lang['UserAdvManager_AdminPassword_Enforced'] = 'Applying to administrators';
-$lang['UserAdvManager_AdminPassword_Enforced_true'] = ' Enable';
-$lang['UserAdvManager_AdminPassword_Enforced_false'] = ' Disable (default)';
-$lang['UserAdvManager_PasswordTest'] = 'Password test: ';
-$lang['UserAdvManager_ScoreTest'] = 'Result: ';
-$lang['UserAdvManager_MailExclusion'] = 'Email domains exclusion';
-$lang['UserAdvManager_MailExclusion_true'] = ' Exclude the following domains:<br>(Use a comma to separate each domain)';
-$lang['UserAdvManager_MailExclusion_false'] = ' Disable (default)';
-
-$lang['UserAdvManager_Mail_Info'] = 'Information email to user:';
-$lang['UserAdvManager_Mail_Info_true'] = ' Enable';
-$lang['UserAdvManager_Mail_Info_false'] = ' Disable (default)';
-$lang['UserAdvManager_MailInfo_Text'] = ' Customizing the information email:';
-$lang['UserAdvManager_Confirm_Mail'] = 'Confirmation of registration:';
-$lang['UserAdvManager_Confirm_Mail_true'] = ' Enable';
-$lang['UserAdvManager_Confirm_Mail_false'] = ' Disable (default)';
-$lang['UserAdvManager_ConfirmMail_Text'] = ' Customizing the confirmation email:';
-$lang['UserAdvManager_Confirm_grpstat_notice'] = 'Caution: It is advisable to use either the group or the validation statutes and not both simultaneously.';
-$lang['UserAdvManager_Confirm_Group'] = 'Validation Groups<br>(leave ------- to not affect group)';
-$lang['UserAdvManager_Confirm_Status'] = 'Validation Statutes<br>(leave ------- to keep the Piwigo\'s default)';
-$lang['UserAdvManager_No_Confirm_Group'] = 'Group for users who have not validated their registration<br>';
-$lang['UserAdvManager_Validated_Group'] = 'Group for users who have validated their registration<br>';
-$lang['UserAdvManager_No_Confirm_Status'] = 'Status for users who have not validated their registration<br>';
-$lang['UserAdvManager_Validated_Status'] = 'Status for users who have validated their registration<br>';
-$lang['UserAdvManager_ValidationLimit_Info'] = 'Deadline for registration validation limited';
-$lang['UserAdvManager_ConfirmMail_TimeOut_true'] = ' Enable. Number of days until expiration: ';
-$lang['UserAdvManager_ConfirmMail_TimeOut_false'] = ' Disable (default)';
-$lang['UserAdvManager_ConfirmMail_Remail'] = 'Remind unvalidated users';
-$lang['UserAdvManager_ConfirmMail_Remail_true'] = ' Enable';
-$lang['UserAdvManager_ConfirmMail_Remail_false'] = ' Disable (default)';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt1'] = 'Customizing the reminder message <b><u>with</u></b> new regeneration of key validation.';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt2'] = 'Customizing the reminder message <b><u>without</u></b> regeneration of key validation.';
-
-$lang['UserAdvManager_GhostTracker'] = 'Ghost visitors management (Ghost Tracker)';
-$lang['UserAdvManager_GhostTracker_true'] = ' Enable. Maximum period in days between two visits: ';
-$lang['UserAdvManager_GhostTracker_false'] = ' Disable (default)';
-$lang['UserAdvManager_GhostTracker_ReminderText'] = 'Customizing Ghost Tracker\'s reminder message';
-$lang['UserAdvManager_LastVisit'] = ' Tracking registered users';
-$lang['UserAdvManager_LastVisit_true'] = ' Enable';
-$lang['UserAdvManager_LastVisit_false'] = ' Disable (default)';
-$lang['UserAdvManager_No_Comment_Anonymous'] = 'Nickname mandatory for guests comments';
-$lang['UserAdvManager_No_Comment_Anonymous_true'] = ' Enable';
-$lang['UserAdvManager_No_Comment_Anonymous_false'] = ' Disable (default)';
-
-$lang['UserAdvManager_Tips1'] = 'Registrations with email validation and warning message on the Piwigo\'s homepage';
-$lang['UserAdvManager_Tips1_txt'] = '
+$lang['UAM_Title1'] = 'Setting restrictions for registrations';
+$lang['UAM_Title2'] = 'Setting confirmations and validations of registration';
+$lang['UAM_Title3'] = 'Setting the followed registrations and other options';
+$lang['UAM_Title4'] = 'Tips and examples of use';
+$lang['UAM_No_Casse'] = 'Usernames: Case sensitivity';
+$lang['UAM_No_Casse_true'] = ' Enable';
+$lang['UAM_No_Casse_false'] = ' Disable (default)';
+$lang['UAM_Username_Char'] = 'Usernames: Exclusion of characters';
+$lang['UAM_Username_Char_true'] = ' Banning characters:<br>(Use a comma to separate each character)<br><br>';
+$lang['UAM_Username_Char_false'] = ' Permit all (default)';
+$lang['UAM_Password_Enforced'] = 'Strengthening the security level of passwords';
+$lang['UAM_Password_Enforced_true'] = ' Enable. Minimum Score: ';
+$lang['UAM_Password_Enforced_false'] = ' Disable (default)';
+$lang['UAM_AdminPassword_Enforced'] = 'Applying to administrators';
+$lang['UAM_AdminPassword_Enforced_true'] = ' Enable';
+$lang['UAM_AdminPassword_Enforced_false'] = ' Disable (default)';
+$lang['UAM_PasswordTest'] = 'Password test: ';
+$lang['UAM_ScoreTest'] = 'Result: ';
+$lang['UAM_MailExclusion'] = 'Email domains exclusion';
+$lang['UAM_MailExclusion_true'] = ' Exclude the following domains:<br>(Use a comma to separate each domain)';
+$lang['UAM_MailExclusion_false'] = ' Disable (default)';
+
+$lang['UAM_Mail_Info'] = 'Information email to user:';
+$lang['UAM_Mail_Info_true'] = ' Enable';
+$lang['UAM_Mail_Info_false'] = ' Disable (default)';
+$lang['UAM_MailInfo_Text'] = ' Customizing the information email:';
+$lang['UAM_Confirm_Mail'] = 'Confirmation of registration:';
+$lang['UAM_Confirm_Mail_true'] = ' Enable';
+$lang['UAM_Confirm_Mail_false'] = ' Disable (default)';
+$lang['UAM_ConfirmMail_Text'] = ' Customizing the confirmation email:';
+$lang['UAM_Confirm_grpstat_notice'] = 'Caution: It is advisable to use either the group or the validation statutes and not both simultaneously.';
+$lang['UAM_Confirm_Group'] = 'Validation Groups<br>(leave ------- to not affect group)';
+$lang['UAM_Confirm_Status'] = 'Validation Statutes<br>(leave ------- to keep the Piwigo\'s default)';
+$lang['UAM_No_Confirm_Group'] = 'Group for users who have not validated their registration<br>';
+$lang['UAM_Validated_Group'] = 'Group for users who have validated their registration<br>';
+$lang['UAM_No_Confirm_Status'] = 'Status for users who have not validated their registration<br>';
+$lang['UAM_Validated_Status'] = 'Status for users who have validated their registration<br>';
+$lang['UAM_ValidationLimit_Info'] = 'Deadline for registration validation limited';
+$lang['UAM_ConfirmMail_TimeOut_true'] = ' Enable. Number of days until expiration: ';
+$lang['UAM_ConfirmMail_TimeOut_false'] = ' Disable (default)';
+$lang['UAM_ConfirmMail_Remail'] = 'Remind unvalidated users';
+$lang['UAM_ConfirmMail_Remail_true'] = ' Enable';
+$lang['UAM_ConfirmMail_Remail_false'] = ' Disable (default)';
+$lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Customizing the reminder message <b><u>with</u></b> new regeneration of key validation.';
+$lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Customizing the reminder message <b><u>without</u></b> regeneration of key validation.';
+
+$lang['UAM_GhostTracker'] = 'Ghost visitors management (Ghost Tracker)';
+$lang['UAM_GhostTracker_true'] = ' Enable. Maximum period in days between two visits: ';
+$lang['UAM_GhostTracker_false'] = ' Disable (default)';
+$lang['UAM_GhostTracker_ReminderText'] = 'Customizing Ghost Tracker\'s reminder message';
+$lang['UAM_LastVisit'] = ' Tracking registered users';
+$lang['UAM_LastVisit_true'] = ' Enable';
+$lang['UAM_LastVisit_false'] = ' Disable (default)';
+$lang['UAM_No_Comment_Anonymous'] = 'Nickname mandatory for guests comments';
+$lang['UAM_No_Comment_Anonymous_true'] = ' Enable';
+$lang['UAM_No_Comment_Anonymous_false'] = ' Disable (default)';
+
+$lang['UAM_Tips1'] = 'Registrations with email validation and warning message on the Piwigo\'s homepage';
+$lang['UAM_Tips1_txt'] = '
           <ul>
             <li>
@@ -245,5 +245,5 @@
 $lang['GT_Init'] = 'Initializing Ghost Tracker';
 $lang['GhostTracker_Title'] = 'Ghost visitors management';
-$lang['UserAdvManager_GhostTracker_Init'] = 'If you enable this feature for the first time or you have reactivated after a long period off during which new visitors are registered, you must initialize or reset the Ghost Tracker. This action is done only after activation or reactivation of the option. Please click <u>once</u> the reset button below.';
+$lang['UAM_GhostTracker_Init'] = 'If you enable this feature for the first time or you have reactivated after a long period off during which new visitors are registered, you must initialize or reset the Ghost Tracker. This action is done only after activation or reactivation of the option. Please click <u>once</u> the reset button below.';
 /* UserList Tab */
 $lang['SubTitle5'] = 'Tracking users';
Index: /extensions/NBC_UserAdvManager/trunk/language/es_ES/plugin.lang.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/language/es_ES/plugin.lang.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/language/es_ES/plugin.lang.php	(revision 5056)
@@ -3,5 +3,5 @@
 global $lang,$conf;
 
-$conf_UserAdvManager = isset($conf['UserAdvManager']) ? explode(";" , $conf['UserAdvManager']) : array();
+$conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 
@@ -24,16 +24,16 @@
 
 /* Errors and Warnings */
-$lang['UserAdvManager_audit_ok'] = 'Auditoría OK';
+$lang['UAM_audit_ok'] = 'Auditoría OK';
 $lang['Err_audit_no_casse'] = '<b>Estas cuentas son idénticos para el caso de cerca:</b> ';
 $lang['Err_audit_username_char'] = '<b>Esta cuenta se utiliza uno o más caracteres prohibidos:</b> ';
 $lang['Err_audit_email_forbidden'] = '<b>Esta cuenta se utiliza un proveedor de correo electrónico está prohibido:</b> ';
 $lang['Err_audit_advise'] = '<b>Usted tiene que realizar correcciones para cumplir con nuevas normas que ha activado.<br>Use una herramienta de gestión de base de datos para corregir las cuentas de usuario directamente en la tabla ###_USERS';
-$lang['UserAdvManager_Empty Author'] = 'El campo de autor tienen que ser llenados para enviar un comentario.';
-if ( isset($conf_UserAdvManager[1]) and $conf_UserAdvManager[1] == 'true' )
+$lang['UAM_Empty Author'] = 'El campo de autor tienen que ser llenados para enviar un comentario.';
+if ( isset($conf_UAM[1]) and $conf_UAM[1] == 'true' )
 	$lang['reg_err_login5'] = 'Nombre de usuario ya existe, el nombre de ADVERTENCIA se distinguen las mayúsculas (Shift = pequeño).';
 $lang['reg_err_login6'] = 'Nombre de usuario no tiene que coincidir con los siguientes caracteres: ';
 $lang['reg_err_login7'] = 'Su proveedor de correo electrónico está prohibido para el registro. Proveedores de correo electrónico en veda son: ';
-$lang['UserAdvManager_empty_pwd'] = '[contraseña vacía]';
-$lang['UserAdvManager_no_update_pwd'] = '[Perfil actualizado sin cambiar contraseña]';
+$lang['UAM_empty_pwd'] = '[contraseña vacía]';
+$lang['UAM_no_update_pwd'] = '[Perfil actualizado sin cambiar contraseña]';
 $lang['invalid_pwd'] = '¡Nombre de usuario o contraseña no válidos!';
 $lang['No_validation_for_Guest'] = 'El "Invitado" cuenta no está sujeta a la validación';
@@ -72,5 +72,5 @@
 $lang['Reminder_Sent_NOK'] = 'NO';
 /* Errors and Warnings */
-$lang['UserAdvManager_save_config'] ='Configuración guardada.';
+$lang['UAM_save_config'] ='Configuración guardada.';
 $lang['reg_err_login3'] = '¡Seguridad: Contraseña es obligatorio!';
 $lang['reg_err_login4_%s'] = 'Seguridad: Un sistema de control calcula la puntuación de la complejidad elegido contraseñas. La complejidad de la contraseña es demasiado baja (puntuación = %s). Por favor, elija una nueva contraseña más segura siguiendo estas reglas:<br>
@@ -123,63 +123,63 @@
 $lang['SubTitle1'] = 'Configuración del plugin';
 $lang['Tab_Global'] = 'Configuración';
-$lang['UserAdvManager_Title1'] = 'Configuración de los restricciones para el registro';
-$lang['UserAdvManager_Title2'] = 'Configuración de las confirmaciones y validaciones de registro';
-$lang['UserAdvManager_Title3'] = 'Configuración de los registros seguido y otras opciones';
-$lang['UserAdvManager_Title4'] = 'Consejos y ejemplos de uso';
-$lang['UserAdvManager_No_Casse'] = 'Nombres de usuario: mayúsculas y minúsculas';
-$lang['UserAdvManager_No_Casse_true'] = ' Activar';
-$lang['UserAdvManager_No_Casse_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_Username_Char'] = 'Nombres de usuario: Excluyendo los caracteres';
-$lang['UserAdvManager_Username_Char_true'] = ' Prohibición de caracteres:<br>(Utilice una coma para separar cada caracteres)<br><br>';
-$lang['UserAdvManager_Username_Char_false'] = ' Permiso de todos (por defecto)';
-$lang['UserAdvManager_Password_Enforced'] = 'Fortalecimiento del nivel de seguridad de las contraseñas';
-$lang['UserAdvManager_Password_Enforced_true'] = ' Activar. Puntuación mínima:';
-$lang['UserAdvManager_Password_Enforced_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_AdminPassword_Enforced'] = 'Aplicando a los administradores';
-$lang['UserAdvManager_AdminPassword_Enforced_true'] = ' Activar';
-$lang['UserAdvManager_AdminPassword_Enforced_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_PasswordTest'] = 'Prueba Contraseña: ';
-$lang['UserAdvManager_ScoreTest'] = 'Resultado: ';
-$lang['UserAdvManager_MailExclusion'] = 'Exclusión de dominios de correo electrónico';
-$lang['UserAdvManager_MailExclusion_true'] = ' Excluir los siguientes dominios: <br>(Utilice una coma para separar cada dominio)';
-$lang['UserAdvManager_MailExclusion_false'] = ' Desactivar (por defecto)';
-
-$lang['UserAdvManager_Mail_Info'] = 'Información por correo electrónico para el usuario:';
-$lang['UserAdvManager_Mail_Info_true'] = ' Activar';
-$lang['UserAdvManager_Mail_Info_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_MailInfo_Text'] = ' Personalización del correo electrónico de información:';
-$lang['UserAdvManager_Confirm_Mail'] = 'Confirmación de registro:';
-$lang['UserAdvManager_Confirm_Mail_true'] = ' Activar';
-$lang['UserAdvManager_Confirm_Mail_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_ConfirmMail_Text'] = ' Personalización del correo electrónico de confirmación:';
-$lang['UserAdvManager_Confirm_grpstat_notice'] = 'Precaución: Es recomendable utilizar el grupo o los estatutos de validación y no ambos simultáneamente.';
-$lang['UserAdvManager_Confirm_Group'] = 'Grupos de validación<br>(Dejar ------- para no afectar grupo)';
-$lang['UserAdvManager_Confirm_Status'] = 'Estatutos de validación<br>(Dejar ------- para mantener el valor predeterminado de Piwigo)';
-$lang['UserAdvManager_No_Confirm_Group'] = 'Grupo para los usuarios que no han validado su registro<br>';
-$lang['UserAdvManager_Validated_Group'] = 'Grupo para los usuarios que han validado su registro<br>';
-$lang['UserAdvManager_No_Confirm_Status'] = 'Situación de los usuarios que no han validado su registro<br>';
-$lang['UserAdvManager_Validated_Status'] = 'Situación de los usuarios que han validado su registro<br>';
-$lang['UserAdvManager_ValidationLimit_Info'] = 'Plazo para la validación de registro limitado';
-$lang['UserAdvManager_ConfirmMail_TimeOut_true'] = ' Activar. Número de días hasta el vencimiento: ';
-$lang['UserAdvManager_ConfirmMail_TimeOut_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_ConfirmMail_Remail'] = 'Recuerde a los usuarios no validados';
-$lang['UserAdvManager_ConfirmMail_Remail_true'] = ' Activar';
-$lang['UserAdvManager_ConfirmMail_Remail_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt1'] = 'Personalización del mensaje recordatorio <b><u>con</u></b> la regeneración de nuevo la validación de claves.';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt2'] = 'Personalización del mensaje recordatorio <b><u>sin</u></b> la regeneración de la validación de claves.';
-
-$lang['UserAdvManager_GhostTracker'] = 'Gestión de Espíritu visitantes (Tracker Ghost)';
-$lang['UserAdvManager_GhostTracker_true'] = ' Activar. Período máximo de días entre dos visitas: ';
-$lang['UserAdvManager_GhostTracker_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_GhostTracker_ReminderText'] = 'Personalización del mensaje recordatorio de Ghost Tracker';
-$lang['UserAdvManager_LastVisit'] = ' Seguimiento de usuarios registrados';
-$lang['UserAdvManager_LastVisit_true'] = ' Activar';
-$lang['UserAdvManager_LastVisit_false'] = ' Desactivar (por defecto)';
-$lang['UserAdvManager_No_Comment_Anonymous'] = 'Nickname obligatorio para los comentarios de los huéspedes';
-$lang['UserAdvManager_No_Comment_Anonymous_true'] = ' Activar';
-$lang['UserAdvManager_No_Comment_Anonymous_false'] = ' Desactivar (por defecto)';
-
-$lang['UserAdvManager_Tips1'] = 'Con la validación de los registros de correo electrónico y mensaje de advertencia en la página principal de Piwigo (ingles)';
-$lang['UserAdvManager_Tips1_txt'] = '
+$lang['UAM_Title1'] = 'Configuración de los restricciones para el registro';
+$lang['UAM_Title2'] = 'Configuración de las confirmaciones y validaciones de registro';
+$lang['UAM_Title3'] = 'Configuración de los registros seguido y otras opciones';
+$lang['UAM_Title4'] = 'Consejos y ejemplos de uso';
+$lang['UAM_No_Casse'] = 'Nombres de usuario: mayúsculas y minúsculas';
+$lang['UAM_No_Casse_true'] = ' Activar';
+$lang['UAM_No_Casse_false'] = ' Desactivar (por defecto)';
+$lang['UAM_Username_Char'] = 'Nombres de usuario: Excluyendo los caracteres';
+$lang['UAM_Username_Char_true'] = ' Prohibición de caracteres:<br>(Utilice una coma para separar cada caracteres)<br><br>';
+$lang['UAM_Username_Char_false'] = ' Permiso de todos (por defecto)';
+$lang['UAM_Password_Enforced'] = 'Fortalecimiento del nivel de seguridad de las contraseñas';
+$lang['UAM_Password_Enforced_true'] = ' Activar. Puntuación mínima:';
+$lang['UAM_Password_Enforced_false'] = ' Desactivar (por defecto)';
+$lang['UAM_AdminPassword_Enforced'] = 'Aplicando a los administradores';
+$lang['UAM_AdminPassword_Enforced_true'] = ' Activar';
+$lang['UAM_AdminPassword_Enforced_false'] = ' Desactivar (por defecto)';
+$lang['UAM_PasswordTest'] = 'Prueba Contraseña: ';
+$lang['UAM_ScoreTest'] = 'Resultado: ';
+$lang['UAM_MailExclusion'] = 'Exclusión de dominios de correo electrónico';
+$lang['UAM_MailExclusion_true'] = ' Excluir los siguientes dominios: <br>(Utilice una coma para separar cada dominio)';
+$lang['UAM_MailExclusion_false'] = ' Desactivar (por defecto)';
+
+$lang['UAM_Mail_Info'] = 'Información por correo electrónico para el usuario:';
+$lang['UAM_Mail_Info_true'] = ' Activar';
+$lang['UAM_Mail_Info_false'] = ' Desactivar (por defecto)';
+$lang['UAM_MailInfo_Text'] = ' Personalización del correo electrónico de información:';
+$lang['UAM_Confirm_Mail'] = 'Confirmación de registro:';
+$lang['UAM_Confirm_Mail_true'] = ' Activar';
+$lang['UAM_Confirm_Mail_false'] = ' Desactivar (por defecto)';
+$lang['UAM_ConfirmMail_Text'] = ' Personalización del correo electrónico de confirmación:';
+$lang['UAM_Confirm_grpstat_notice'] = 'Precaución: Es recomendable utilizar el grupo o los estatutos de validación y no ambos simultáneamente.';
+$lang['UAM_Confirm_Group'] = 'Grupos de validación<br>(Dejar ------- para no afectar grupo)';
+$lang['UAM_Confirm_Status'] = 'Estatutos de validación<br>(Dejar ------- para mantener el valor predeterminado de Piwigo)';
+$lang['UAM_No_Confirm_Group'] = 'Grupo para los usuarios que no han validado su registro<br>';
+$lang['UAM_Validated_Group'] = 'Grupo para los usuarios que han validado su registro<br>';
+$lang['UAM_No_Confirm_Status'] = 'Situación de los usuarios que no han validado su registro<br>';
+$lang['UAM_Validated_Status'] = 'Situación de los usuarios que han validado su registro<br>';
+$lang['UAM_ValidationLimit_Info'] = 'Plazo para la validación de registro limitado';
+$lang['UAM_ConfirmMail_TimeOut_true'] = ' Activar. Número de días hasta el vencimiento: ';
+$lang['UAM_ConfirmMail_TimeOut_false'] = ' Desactivar (por defecto)';
+$lang['UAM_ConfirmMail_Remail'] = 'Recuerde a los usuarios no validados';
+$lang['UAM_ConfirmMail_Remail_true'] = ' Activar';
+$lang['UAM_ConfirmMail_Remail_false'] = ' Desactivar (por defecto)';
+$lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Personalización del mensaje recordatorio <b><u>con</u></b> la regeneración de nuevo la validación de claves.';
+$lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Personalización del mensaje recordatorio <b><u>sin</u></b> la regeneración de la validación de claves.';
+
+$lang['UAM_GhostTracker'] = 'Gestión de Espíritu visitantes (Tracker Ghost)';
+$lang['UAM_GhostTracker_true'] = ' Activar. Período máximo de días entre dos visitas: ';
+$lang['UAM_GhostTracker_false'] = ' Desactivar (por defecto)';
+$lang['UAM_GhostTracker_ReminderText'] = 'Personalización del mensaje recordatorio de Ghost Tracker';
+$lang['UAM_LastVisit'] = ' Seguimiento de usuarios registrados';
+$lang['UAM_LastVisit_true'] = ' Activar';
+$lang['UAM_LastVisit_false'] = ' Desactivar (por defecto)';
+$lang['UAM_No_Comment_Anonymous'] = 'Nickname obligatorio para los comentarios de los huéspedes';
+$lang['UAM_No_Comment_Anonymous_true'] = ' Activar';
+$lang['UAM_No_Comment_Anonymous_false'] = ' Desactivar (por defecto)';
+
+$lang['UAM_Tips1'] = 'Con la validación de los registros de correo electrónico y mensaje de advertencia en la página principal de Piwigo (ingles)';
+$lang['UAM_Tips1_txt'] = '
           <ul>
             <li>
@@ -245,5 +245,5 @@
 $lang['GT_Init'] = 'Inicialización Ghost Tracker';
 $lang['GhostTracker_Title'] = 'Gestión de los espíritu visitantes';
-$lang['UserAdvManager_GhostTracker_Init'] = 'Si habilita esta función por primera vez o ha reactivado después de un largo período durante el cual los visitantes fuera de nuevo se ha registrado, usted debe inicializar o restablecer el Rastreador de Ghost. Esta acción se realiza sólo después de la activación o reactivación de la opción. Por favor, haga clic en <u>una vez</u> el botón de reset de abajo.';
+$lang['UAM_GhostTracker_Init'] = 'Si habilita esta función por primera vez o ha reactivado después de un largo período durante el cual los visitantes fuera de nuevo se ha registrado, usted debe inicializar o restablecer el Rastreador de Ghost. Esta acción se realiza sólo después de la activación o reactivación de la opción. Por favor, haga clic en <u>una vez</u> el botón de reset de abajo.';
 /* UserList Tab */
 $lang['SubTitle5'] = 'Seguimiento de los usuarios';
Index: /extensions/NBC_UserAdvManager/trunk/language/fr_FR/plugin.lang.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/language/fr_FR/plugin.lang.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/language/fr_FR/plugin.lang.php	(revision 5056)
@@ -3,5 +3,5 @@
 global $lang,$conf;
 
-$conf_UserAdvManager = isset($conf['UserAdvManager']) ? explode(";" , $conf['UserAdvManager']) : array();
+$conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 
@@ -24,16 +24,16 @@
 
 /* Errors and Warnings */
-$lang['UserAdvManager_audit_ok'] = 'Audit OK';
+$lang['UAM_audit_ok'] = 'Audit OK';
 $lang['Err_audit_no_casse'] = '<b>Ces comptes sont identiques à la casse près :</b> ';
 $lang['Err_audit_username_char'] = '<b>Ce compte contient un ou des caractères interdits :</b> ';
 $lang['Err_audit_email_forbidden'] = '<b>Ce compte contient des domaines de messagerie interdit :</b> ';
 $lang['Err_audit_advise'] = '<b>Vous avez des corrections a faire pour respecter les nouvelles règles que vous avez activées.<br>Utilisez un utilitaire de gestion de base de données pour corriger les comptes utilisateurs directement dans la table ###_USERS si nécessaire.</b><br><br>';
-$lang['UserAdvManager_Empty Author'] = 'Le champs auteur doit être rempli pour enregistrer un commentaire.';
-if ( isset($conf_UserAdvManager[1]) and $conf_UserAdvManager[1] == 'true' )
+$lang['UAM_Empty Author'] = 'Le champs auteur doit être rempli pour enregistrer un commentaire.';
+if ( isset($conf_UAM[1]) and $conf_UAM[1] == 'true' )
 	$lang['reg_err_login5'] = 'ce nom utilisateur est déjà pris, ATTENTION le nom est insensible à la casse (Majuscule = Minuscule).';
 $lang['reg_err_login6'] = 'le nom utilisateur ne doit pas contenir les caractère suivants : ';
 $lang['reg_err_login7'] = 'L\'adresse email est issue d\'un prestataire interdit. Les prestataires d\'adresses email interdits à l\'inscription sont : ';
-$lang['UserAdvManager_empty_pwd'] = '[mot de passe vide]';
-$lang['UserAdvManager_no_update_pwd'] = '[mise à jour du profil sans changement du mot de passe]';
+$lang['UAM_empty_pwd'] = '[mot de passe vide]';
+$lang['UAM_no_update_pwd'] = '[mise à jour du profil sans changement du mot de passe]';
 $lang['invalid_pwd'] = 'Nom utilisateur ou Mot de passe invalide !';
 $lang['No_validation_for_Guest'] = 'Le compte Guest n\'est pas soumis à validation';
@@ -72,5 +72,5 @@
 $lang['Reminder_Sent_NOK'] = 'NON';
 /* Errors and Warnings */
-$lang['UserAdvManager_save_config'] ='Configuration enregistrée.';
+$lang['UAM_save_config'] ='Configuration enregistrée.';
 $lang['reg_err_login3'] = 'Sécurité : Le mot de passe est obligatoire !';
 $lang['reg_err_login4_%s'] = 'Sécurité : Un système de contrôle calcule un score de complexité sur les mots de passe choisis. La complexité de votre mot de passe est trop faible (score = %s). Veuillez choisir un nouveau mot de passe plus sûre en respectant les règles suivantes :<br>
@@ -124,63 +124,63 @@
 $lang['SubTitle1'] = 'Configuration du plugin';
 $lang['Tab_Global'] = 'Configuration';
-$lang['UserAdvManager_Title1'] = 'Paramétrage des restrictions d\'inscriptions';
-$lang['UserAdvManager_Title2'] = 'Paramétrage des confirmations et validations d\'inscriptions';
-$lang['UserAdvManager_Title3'] = 'Paramétrage des suivis des inscrits et autres options';
-$lang['UserAdvManager_Title4'] = 'Astuces et exemples d\'utilisation';
-$lang['UserAdvManager_No_Casse'] = 'Noms d\'utilisateurs : Sensibilité à la casse';
-$lang['UserAdvManager_No_Casse_true'] = ' Activer';
-$lang['UserAdvManager_No_Casse_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_Username_Char'] = 'Noms d\'utilisateurs : Exclusion de certains caractères';
-$lang['UserAdvManager_Username_Char_true'] = ' Interdire les caractères:<br>(utiliser une virgule pour séparer chaque caractère du suivant)<br><br>';
-$lang['UserAdvManager_Username_Char_false'] = ' Tout autoriser (valeur par défaut)';
-$lang['UserAdvManager_Password_Enforced'] = 'Renforcement de la sécurité des mots de passe';
-$lang['UserAdvManager_Password_Enforced_true'] = ' Activer. Score minimum: ';
-$lang['UserAdvManager_Password_Enforced_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_AdminPassword_Enforced'] = 'Application aux administrateurs';
-$lang['UserAdvManager_AdminPassword_Enforced_true'] = ' Activer';
-$lang['UserAdvManager_AdminPassword_Enforced_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_PasswordTest'] = 'Mot de passe test: ';
-$lang['UserAdvManager_ScoreTest'] = 'Résultat: ';
-$lang['UserAdvManager_MailExclusion'] = 'Exclusion des domaines de messagerie';
-$lang['UserAdvManager_MailExclusion_true'] = ' Exclure les domaines suivants:<br>(utiliser une virgule pour séparer chaque domaine du suivant)';
-$lang['UserAdvManager_MailExclusion_false'] = ' Désactiver (valeur par défaut)';
-
-$lang['UserAdvManager_Mail_Info'] = 'Email d\'information à l\'utilisateur:';
-$lang['UserAdvManager_Mail_Info_true'] = ' Activer';
-$lang['UserAdvManager_Mail_Info_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_MailInfo_Text'] = ' Texte d\'accueil personnalisé:';
-$lang['UserAdvManager_Confirm_Mail'] = 'Confirmation d\'inscription:';
-$lang['UserAdvManager_Confirm_Mail_true'] = ' Activer';
-$lang['UserAdvManager_Confirm_Mail_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_ConfirmMail_Text'] = ' Texte d\'accueil personnalisé:';
-$lang['UserAdvManager_Confirm_Group'] = 'Groupes de validation<br>(------- pour ne pas affecter de groupe)';
-$lang['UserAdvManager_Confirm_Status'] = 'Statuts de validation<br>(------- pour conserver la valeur par défaut de Piwigo)';
-$lang['UserAdvManager_Confirm_grpstat_notice'] = 'Attention : Il est conseillé d\'utiliser soit les groupes, soit les statuts de validation et pas les deux simultanément.';
-$lang['UserAdvManager_No_Confirm_Group'] = 'Pour les utilisateurs n\'ayant pas validé leur inscription<br>';
-$lang['UserAdvManager_Validated_Group'] = 'Pour les utilisateurs ayant validé leur inscription<br>';
-$lang['UserAdvManager_No_Confirm_Status'] = 'Pour les utilisateurs n\'ayant pas validé leur inscription<br>';
-$lang['UserAdvManager_Validated_Status'] = 'Pour les utilisateurs ayant validé leur inscription.<br>';
-$lang['UserAdvManager_ValidationLimit_Info'] = 'Limitation du délai de validation d\'inscription';
-$lang['UserAdvManager_ConfirmMail_TimeOut_true'] = ' Activer. Nombre de jours de délai: ';
-$lang['UserAdvManager_ConfirmMail_TimeOut_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_ConfirmMail_Remail'] = 'Mail de rappel aux inscrits non validés';
-$lang['UserAdvManager_ConfirmMail_Remail_true'] = ' Activer';
-$lang['UserAdvManager_ConfirmMail_Remail_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt1'] = 'Texte du message de rappel <b><u>avec</u></b> génération d\'une nouvelle clé de validation.';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt2'] = 'Texte du message de rappel <b><u>sans</u></b> génération d\'une nouvelle clé de validation.';
-
-$lang['UserAdvManager_GhostTracker'] = 'Gestion des visiteurs fantômes (Ghost Tracker)';
-$lang['UserAdvManager_GhostTracker_true'] = ' Activer. Nombre de jours maximum entre deux visites: ';
-$lang['UserAdvManager_GhostTracker_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_GhostTracker_ReminderText'] = 'Texte de rappel personnalisé';
-$lang['UserAdvManager_LastVisit'] = ' Suivi des utilisateurs inscrits';
-$lang['UserAdvManager_LastVisit_true'] = ' Activer';
-$lang['UserAdvManager_LastVisit_false'] = ' Désactiver (valeur par défaut)';
-$lang['UserAdvManager_No_Comment_Anonymous'] = 'Commentaires : pseudo obligatoire pour les non-inscrits';
-$lang['UserAdvManager_No_Comment_Anonymous_true'] = ' Activer';
-$lang['UserAdvManager_No_Comment_Anonymous_false'] = ' Désactiver (valeur par défaut)';
-
-$lang['UserAdvManager_Tips1'] = 'Inscriptions avec validation par email et message d\'avertissement sur la page d\'accueil de Piwigo';
-$lang['UserAdvManager_Tips1_txt'] = '
+$lang['UAM_Title1'] = 'Paramétrage des restrictions d\'inscriptions';
+$lang['UAM_Title2'] = 'Paramétrage des confirmations et validations d\'inscriptions';
+$lang['UAM_Title3'] = 'Paramétrage des suivis des inscrits et autres options';
+$lang['UAM_Title4'] = 'Astuces et exemples d\'utilisation';
+$lang['UAM_No_Casse'] = 'Noms d\'utilisateurs : Sensibilité à la casse';
+$lang['UAM_No_Casse_true'] = ' Activer';
+$lang['UAM_No_Casse_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_Username_Char'] = 'Noms d\'utilisateurs : Exclusion de certains caractères';
+$lang['UAM_Username_Char_true'] = ' Interdire les caractères:<br>(utiliser une virgule pour séparer chaque caractère du suivant)<br><br>';
+$lang['UAM_Username_Char_false'] = ' Tout autoriser (valeur par défaut)';
+$lang['UAM_Password_Enforced'] = 'Renforcement de la sécurité des mots de passe';
+$lang['UAM_Password_Enforced_true'] = ' Activer. Score minimum: ';
+$lang['UAM_Password_Enforced_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_AdminPassword_Enforced'] = 'Application aux administrateurs';
+$lang['UAM_AdminPassword_Enforced_true'] = ' Activer';
+$lang['UAM_AdminPassword_Enforced_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_PasswordTest'] = 'Mot de passe test: ';
+$lang['UAM_ScoreTest'] = 'Résultat: ';
+$lang['UAM_MailExclusion'] = 'Exclusion des domaines de messagerie';
+$lang['UAM_MailExclusion_true'] = ' Exclure les domaines suivants:<br>(utiliser une virgule pour séparer chaque domaine du suivant)';
+$lang['UAM_MailExclusion_false'] = ' Désactiver (valeur par défaut)';
+
+$lang['UAM_Mail_Info'] = 'Email d\'information à l\'utilisateur:';
+$lang['UAM_Mail_Info_true'] = ' Activer';
+$lang['UAM_Mail_Info_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_MailInfo_Text'] = ' Texte d\'accueil personnalisé:';
+$lang['UAM_Confirm_Mail'] = 'Confirmation d\'inscription:';
+$lang['UAM_Confirm_Mail_true'] = ' Activer';
+$lang['UAM_Confirm_Mail_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_ConfirmMail_Text'] = ' Texte d\'accueil personnalisé:';
+$lang['UAM_Confirm_Group'] = 'Groupes de validation<br>(------- pour ne pas affecter de groupe)';
+$lang['UAM_Confirm_Status'] = 'Statuts de validation<br>(------- pour conserver la valeur par défaut de Piwigo)';
+$lang['UAM_Confirm_grpstat_notice'] = 'Attention : Il est conseillé d\'utiliser soit les groupes, soit les statuts de validation et pas les deux simultanément.';
+$lang['UAM_No_Confirm_Group'] = 'Pour les utilisateurs n\'ayant pas validé leur inscription<br>';
+$lang['UAM_Validated_Group'] = 'Pour les utilisateurs ayant validé leur inscription<br>';
+$lang['UAM_No_Confirm_Status'] = 'Pour les utilisateurs n\'ayant pas validé leur inscription<br>';
+$lang['UAM_Validated_Status'] = 'Pour les utilisateurs ayant validé leur inscription.<br>';
+$lang['UAM_ValidationLimit_Info'] = 'Limitation du délai de validation d\'inscription';
+$lang['UAM_ConfirmMail_TimeOut_true'] = ' Activer. Nombre de jours de délai: ';
+$lang['UAM_ConfirmMail_TimeOut_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_ConfirmMail_Remail'] = 'Mail de rappel aux inscrits non validés';
+$lang['UAM_ConfirmMail_Remail_true'] = ' Activer';
+$lang['UAM_ConfirmMail_Remail_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Texte du message de rappel <b><u>avec</u></b> génération d\'une nouvelle clé de validation.';
+$lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Texte du message de rappel <b><u>sans</u></b> génération d\'une nouvelle clé de validation.';
+
+$lang['UAM_GhostTracker'] = 'Gestion des visiteurs fantômes (Ghost Tracker)';
+$lang['UAM_GhostTracker_true'] = ' Activer. Nombre de jours maximum entre deux visites: ';
+$lang['UAM_GhostTracker_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_GhostTracker_ReminderText'] = 'Texte de rappel personnalisé';
+$lang['UAM_LastVisit'] = ' Suivi des utilisateurs inscrits';
+$lang['UAM_LastVisit_true'] = ' Activer';
+$lang['UAM_LastVisit_false'] = ' Désactiver (valeur par défaut)';
+$lang['UAM_No_Comment_Anonymous'] = 'Commentaires : pseudo obligatoire pour les non-inscrits';
+$lang['UAM_No_Comment_Anonymous_true'] = ' Activer';
+$lang['UAM_No_Comment_Anonymous_false'] = ' Désactiver (valeur par défaut)';
+
+$lang['UAM_Tips1'] = 'Inscriptions avec validation par email et message d\'avertissement sur la page d\'accueil de Piwigo';
+$lang['UAM_Tips1_txt'] = '
           <ul>
             <li>
@@ -246,5 +246,5 @@
 $lang['GT_Init'] = 'Initialisation du Ghost Tracker';
 $lang['GhostTracker_Title'] = 'Gestion des visiteurs fantômes';
-$lang['UserAdvManager_GhostTracker_Init'] = 'A première activation de cette fonction, ou à sa réactivation après une longue période pendant laquelle de nouveaux visiteurs se sont inscrits, il convient d\'initialiser ou de réinitialiser le Ghost Tracker. Cette action n\'est à faire qu\'une seule fois après activation ou réactivation de l\'option; à cet effet, cliquez <u>une seule fois</u> sur le bouton d\'initialisation ci-dessous.</b>';
+$lang['UAM_GhostTracker_Init'] = 'A première activation de cette fonction, ou à sa réactivation après une longue période pendant laquelle de nouveaux visiteurs se sont inscrits, il convient d\'initialiser ou de réinitialiser le Ghost Tracker. Cette action n\'est à faire qu\'une seule fois après activation ou réactivation de l\'option; à cet effet, cliquez <u>une seule fois</u> sur le bouton d\'initialisation ci-dessous.</b>';
 /* UserList Tab */
 $lang['SubTitle5'] = 'Informations sur les utilisateurs';
Index: /extensions/NBC_UserAdvManager/trunk/language/it_IT/plugin.lang.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/language/it_IT/plugin.lang.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/language/it_IT/plugin.lang.php	(revision 5056)
@@ -3,5 +3,5 @@
 global $lang,$conf;
 
-$conf_UserAdvManager = isset($conf['UserAdvManager']) ? explode(";" , $conf['UserAdvManager']) : array();
+$conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 
@@ -24,16 +24,16 @@
 
 /* Errors and Warnings */
-$lang['UserAdvManager_audit_ok'] = 'Audit OK';
+$lang['UAM_audit_ok'] = 'Audit OK';
 $lang['Err_audit_no_casse'] = '<b>Questi conti sono identici al caso da vicino:</b> ';
 $lang['Err_audit_username_char'] = '<b>Questo conto utente utilizza uno o più caratteri vietati:</b> ';
 $lang['Err_audit_email_forbidden'] = '<b>Questo conto utente usa un dominio di email proibito:</b> ';
 $lang['Err_audit_advise'] = '<b>è necessario eseguire correzioni per conformarsi alle nuove regole che sono state attivate.<br>Utilizzare un programma per la gestione di database per correggere gli account utente direttamente nella tabella ###_USERS';
-$lang['UserAdvManager_Empty Author'] = 'Il campo autore devono essere riempiti per inviare un commento.';
-if ( isset($conf_UserAdvManager[1]) and $conf_UserAdvManager[1] == 'true' )
+$lang['UAM_Empty Author'] = 'Il campo autore devono essere riempiti per inviare un commento.';
+if ( isset($conf_UAM[1]) and $conf_UAM[1] == 'true' )
 	$lang['reg_err_login5'] = 'Nome utente esistono già, il nome di richiamo è case insensitive (Shift = Tiny).';
 $lang['reg_err_login6'] = 'Nome utente non deve corrispondere i seguenti caratteri: ';
 $lang['reg_err_login7'] = 'Il tuo provider di posta elettronica è vietato per la registrazione. Vietato provider di posta elettronica sono i seguenti: ';
-$lang['UserAdvManager_empty_pwd'] = '[password vuota]';
-$lang['UserAdvManager_no_update_pwd'] = '[profilo aggiornato senza password cambiata]';
+$lang['UAM_empty_pwd'] = '[password vuota]';
+$lang['UAM_no_update_pwd'] = '[profilo aggiornato senza password cambiata]';
 $lang['invalid_pwd'] = 'Nome utente o password non validi!';
 $lang['No_validation_for_Guest'] = '"Guest" conto non è soggetta a convalida';
@@ -72,5 +72,5 @@
 $lang['Reminder_Sent_NOK'] = 'NO';
 /* Errors and Warnings */
-$lang['UserAdvManager_save_config'] ='Configurazione salvata.';
+$lang['UAM_save_config'] ='Configurazione salvata.';
 $lang['reg_err_login3'] = 'Security: Password è obbligatorio!';
 $lang['reg_err_login4_%s'] = 'Sicurezza: un sistema di controllo calcola un punteggio sulla scelta password complessità. La complessità della password è troppo bassa (punteggio = %s). Si prega di scegliere una nuova password più sicura seguendo queste regole:<br>
@@ -123,63 +123,63 @@
 $lang['SubTitle1'] = 'Configurazione dei plugin';
 $lang['Tab_Global'] = 'Configurazione';
-$lang['UserAdvManager_Title1'] = 'Impostare le restrizioni per le registrazioni';
-$lang['UserAdvManager_Title2'] = 'Impostare le conferme e validazioni di registrazione';
-$lang['UserAdvManager_Title3'] = 'Impostare le registrazioni seguiti e altre opzioni';
-$lang['UserAdvManager_Title4'] = 'Suggerimenti ed esempi di utilizzo';
-$lang['UserAdvManager_No_Casse'] = 'Nome utente: Sensibilità case';
-$lang['UserAdvManager_No_Casse_true'] = ' Consentire';
-$lang['UserAdvManager_No_Casse_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_Username_Char'] = 'Nome utente: Esclusione di caratteri';
-$lang['UserAdvManager_Username_Char_true'] = ' Divieto di caratteri:<br>(Utilizzare una virgola per separare ogni carattere)<br><br>';
-$lang['UserAdvManager_Username_Char_false'] = ' Consentire a tutti (predefinito)';
-$lang['UserAdvManager_Password_Enforced'] = 'Rafforzare il livello di sicurezza delle password';
-$lang['UserAdvManager_Password_Enforced_true'] = ' Consentire. Punteggio minimo: ';
-$lang['UserAdvManager_Password_Enforced_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_AdminPassword_Enforced'] = 'Applicando agli amministratori';
-$lang['UserAdvManager_AdminPassword_Enforced_true'] = ' Consentire';
-$lang['UserAdvManager_AdminPassword_Enforced_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_PasswordTest'] = 'Password di prova: ';
-$lang['UserAdvManager_ScoreTest'] = 'Risultato: ';
-$lang['UserAdvManager_MailExclusion'] = 'L\'esclusione Email domini';
-$lang['UserAdvManager_MailExclusion_true'] = ' Escludi i seguenti domini:<br>(Utilizzare una virgola per separare ogni dominio)';
-$lang['UserAdvManager_MailExclusion_false'] = ' Disattivare (predefinito)';
-
-$lang['UserAdvManager_Mail_Info'] = 'E-mail informazioni per l\'utente:';
-$lang['UserAdvManager_Mail_Info_true'] = ' Consentire';
-$lang['UserAdvManager_Mail_Info_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_MailInfo_Text'] = ' Personalizzazione e-mail informazioni:';
-$lang['UserAdvManager_Confirm_Mail'] = 'Conferma della registrazione:';
-$lang['UserAdvManager_Confirm_Mail_true'] = ' Consentire';
-$lang['UserAdvManager_Confirm_Mail_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_ConfirmMail_Text'] = ' Personalizzare la mail di conferma:';
-$lang['UserAdvManager_Confirm_grpstat_notice'] = 'ATTENZIONE: Si consiglia di utilizzare sia il gruppo o lo statuto di convalida e non entrambi simultaneamente.';
-$lang['UserAdvManager_Confirm_Group'] = 'Gruppi di convalida<br>(Invia ------- non pregiudicare gruppo)';
-$lang['UserAdvManager_Confirm_Status'] = 'Convalida Statuti<br>(Invia ------- per mantenere il default di Piwigo)';
-$lang['UserAdvManager_No_Confirm_Group'] = 'Gruppo per gli utenti che non hanno convalidato la loro registrazione<br>';
-$lang['UserAdvManager_Validated_Group'] = 'Gruppo per gli utenti che hanno convalidato la loro iscrizione<br>';
-$lang['UserAdvManager_No_Confirm_Status'] = 'Di stato per gli utenti che non hanno convalidato la loro registrazione<br>';
-$lang['UserAdvManager_Validated_Status'] = 'Stato per gli utenti che hanno convalidato la loro iscrizione<br>';
-$lang['UserAdvManager_ValidationLimit_Info'] = 'Termine per la validazione di registrazione limitato';
-$lang['UserAdvManager_ConfirmMail_TimeOut_true'] = ' Consentire. Numero di giorni fino alla scadenza: ';
-$lang['UserAdvManager_ConfirmMail_TimeOut_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_ConfirmMail_Remail'] = 'Promemoria visitatori non convalidate';
-$lang['UserAdvManager_ConfirmMail_Remail_true'] = ' Consentire';
-$lang['UserAdvManager_ConfirmMail_Remail_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt1'] = 'Personalizzare il messaggio di sollecito <b><u>con</u></b> nuova rigenerazione di convalida delle chiavi.';
-$lang['UserAdvManager_ConfirmMail_ReMail_Txt2'] = 'Personalizzazione del messaggio di sollecito <b><u>senza</u></b> rigenerazione della convalida delle chiavi.';
-
-$lang['UserAdvManager_GhostTracker'] = 'Gestione fantasmi visitatori (Ghost Tracker)';
-$lang['UserAdvManager_GhostTracker_true'] = ' Consentire. Durata massima in giorni tra due visite: ';
-$lang['UserAdvManager_GhostTracker_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_GhostTracker_ReminderText'] = 'Personalizzazione richiamo di messaggi del Ghost Tracker';
-$lang['UserAdvManager_LastVisit'] = ' Tracciamento utenti registrati';
-$lang['UserAdvManager_LastVisit_true'] = ' Consentire';
-$lang['UserAdvManager_LastVisit_false'] = ' Disattivare (predefinito)';
-$lang['UserAdvManager_No_Comment_Anonymous'] = 'Nickname obbligatoria per i commenti degli ospiti';
-$lang['UserAdvManager_No_Comment_Anonymous_true'] = ' Consentire';
-$lang['UserAdvManager_No_Comment_Anonymous_false'] = ' Disattivare (predefinito)';
-
-$lang['UserAdvManager_Tips1'] = 'Registrazioni con la convalida e-mail e messaggio di avviso nella home page del PhpWebGallery (Inglese)';
-/* TODO */$lang['UserAdvManager_Tips1_txt'] = '
+$lang['UAM_Title1'] = 'Impostare le restrizioni per le registrazioni';
+$lang['UAM_Title2'] = 'Impostare le conferme e validazioni di registrazione';
+$lang['UAM_Title3'] = 'Impostare le registrazioni seguiti e altre opzioni';
+$lang['UAM_Title4'] = 'Suggerimenti ed esempi di utilizzo';
+$lang['UAM_No_Casse'] = 'Nome utente: Sensibilità case';
+$lang['UAM_No_Casse_true'] = ' Consentire';
+$lang['UAM_No_Casse_false'] = ' Disattivare (predefinito)';
+$lang['UAM_Username_Char'] = 'Nome utente: Esclusione di caratteri';
+$lang['UAM_Username_Char_true'] = ' Divieto di caratteri:<br>(Utilizzare una virgola per separare ogni carattere)<br><br>';
+$lang['UAM_Username_Char_false'] = ' Consentire a tutti (predefinito)';
+$lang['UAM_Password_Enforced'] = 'Rafforzare il livello di sicurezza delle password';
+$lang['UAM_Password_Enforced_true'] = ' Consentire. Punteggio minimo: ';
+$lang['UAM_Password_Enforced_false'] = ' Disattivare (predefinito)';
+$lang['UAM_AdminPassword_Enforced'] = 'Applicando agli amministratori';
+$lang['UAM_AdminPassword_Enforced_true'] = ' Consentire';
+$lang['UAM_AdminPassword_Enforced_false'] = ' Disattivare (predefinito)';
+$lang['UAM_PasswordTest'] = 'Password di prova: ';
+$lang['UAM_ScoreTest'] = 'Risultato: ';
+$lang['UAM_MailExclusion'] = 'L\'esclusione Email domini';
+$lang['UAM_MailExclusion_true'] = ' Escludi i seguenti domini:<br>(Utilizzare una virgola per separare ogni dominio)';
+$lang['UAM_MailExclusion_false'] = ' Disattivare (predefinito)';
+
+$lang['UAM_Mail_Info'] = 'E-mail informazioni per l\'utente:';
+$lang['UAM_Mail_Info_true'] = ' Consentire';
+$lang['UAM_Mail_Info_false'] = ' Disattivare (predefinito)';
+$lang['UAM_MailInfo_Text'] = ' Personalizzazione e-mail informazioni:';
+$lang['UAM_Confirm_Mail'] = 'Conferma della registrazione:';
+$lang['UAM_Confirm_Mail_true'] = ' Consentire';
+$lang['UAM_Confirm_Mail_false'] = ' Disattivare (predefinito)';
+$lang['UAM_ConfirmMail_Text'] = ' Personalizzare la mail di conferma:';
+$lang['UAM_Confirm_grpstat_notice'] = 'ATTENZIONE: Si consiglia di utilizzare sia il gruppo o lo statuto di convalida e non entrambi simultaneamente.';
+$lang['UAM_Confirm_Group'] = 'Gruppi di convalida<br>(Invia ------- non pregiudicare gruppo)';
+$lang['UAM_Confirm_Status'] = 'Convalida Statuti<br>(Invia ------- per mantenere il default di Piwigo)';
+$lang['UAM_No_Confirm_Group'] = 'Gruppo per gli utenti che non hanno convalidato la loro registrazione<br>';
+$lang['UAM_Validated_Group'] = 'Gruppo per gli utenti che hanno convalidato la loro iscrizione<br>';
+$lang['UAM_No_Confirm_Status'] = 'Di stato per gli utenti che non hanno convalidato la loro registrazione<br>';
+$lang['UAM_Validated_Status'] = 'Stato per gli utenti che hanno convalidato la loro iscrizione<br>';
+$lang['UAM_ValidationLimit_Info'] = 'Termine per la validazione di registrazione limitato';
+$lang['UAM_ConfirmMail_TimeOut_true'] = ' Consentire. Numero di giorni fino alla scadenza: ';
+$lang['UAM_ConfirmMail_TimeOut_false'] = ' Disattivare (predefinito)';
+$lang['UAM_ConfirmMail_Remail'] = 'Promemoria visitatori non convalidate';
+$lang['UAM_ConfirmMail_Remail_true'] = ' Consentire';
+$lang['UAM_ConfirmMail_Remail_false'] = ' Disattivare (predefinito)';
+$lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Personalizzare il messaggio di sollecito <b><u>con</u></b> nuova rigenerazione di convalida delle chiavi.';
+$lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Personalizzazione del messaggio di sollecito <b><u>senza</u></b> rigenerazione della convalida delle chiavi.';
+
+$lang['UAM_GhostTracker'] = 'Gestione fantasmi visitatori (Ghost Tracker)';
+$lang['UAM_GhostTracker_true'] = ' Consentire. Durata massima in giorni tra due visite: ';
+$lang['UAM_GhostTracker_false'] = ' Disattivare (predefinito)';
+$lang['UAM_GhostTracker_ReminderText'] = 'Personalizzazione richiamo di messaggi del Ghost Tracker';
+$lang['UAM_LastVisit'] = ' Tracciamento utenti registrati';
+$lang['UAM_LastVisit_true'] = ' Consentire';
+$lang['UAM_LastVisit_false'] = ' Disattivare (predefinito)';
+$lang['UAM_No_Comment_Anonymous'] = 'Nickname obbligatoria per i commenti degli ospiti';
+$lang['UAM_No_Comment_Anonymous_true'] = ' Consentire';
+$lang['UAM_No_Comment_Anonymous_false'] = ' Disattivare (predefinito)';
+
+$lang['UAM_Tips1'] = 'Registrazioni con la convalida e-mail e messaggio di avviso nella home page del PhpWebGallery (Inglese)';
+/* TODO */$lang['UAM_Tips1_txt'] = '
           <ul>
             <li>
@@ -245,5 +245,5 @@
 $lang['GT_Init'] = 'Inizializzazione Ghost Tracker';
 $lang['GhostTracker_Title'] = 'Gestione fantasmi visitatori';
-$lang['UserAdvManager_GhostTracker_Init'] = 'Se si attiva questa funzione per la prima volta o che hanno riattivato, dopo un lungo periodo fuori durante il quale i nuovi visitatori sono registrati, è necessario inizializzare o azzerare il Tracker Ghost. Questa azione viene effettuata solo dopo l\'attivazione o la riattivazione del contratto stesso. Si prega di scegliere <u>una volta</u> il pulsante di reset sotto.';
+$lang['UAM_GhostTracker_Init'] = 'Se si attiva questa funzione per la prima volta o che hanno riattivato, dopo un lungo periodo fuori durante il quale i nuovi visitatori sono registrati, è necessario inizializzare o azzerare il Tracker Ghost. Questa azione viene effettuata solo dopo l\'attivazione o la riattivazione del contratto stesso. Si prega di scegliere <u>una volta</u> il pulsante di reset sotto.';
 /* UserList Tab */
 $lang['SubTitle5'] = 'Tracciamento degli utenti';
Index: /extensions/NBC_UserAdvManager/trunk/main.inc.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/main.inc.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/main.inc.php	(revision 5056)
@@ -2,5 +2,5 @@
 /*
 Plugin Name: NBC UserAdvManager
-Version: 2.13.4
+Version: 2.13.5
 Description: Renforcer la gestion des utilisateurs - Enforce users management
 Plugin URI: http://fr.piwigo.org/ext/extension_view.php?eid=216
@@ -42,5 +42,5 @@
 
 include_once (NBC_UAM_PATH.'include/constants.php');
-include_once (NBC_UAM_PATH.'include/functions_UserAdvManager.inc.php');
+include_once (NBC_UAM_PATH.'include/functions.inc.php');
 
 load_language('plugin.lang', NBC_UAM_PATH);
@@ -48,12 +48,12 @@
 
 /* Plugin admin */
-add_event_handler('get_admin_plugin_menu_links', 'nbc_UserAdvManager_admin_menu');
-
-function nbc_UserAdvManager_admin_menu($menu)
+add_event_handler('get_admin_plugin_menu_links', 'UAM_admin_menu');
+
+function UAM_admin_menu($menu)
 {
   array_push($menu,
     array(
       'NAME' => 'UserAdvManager',
-      'URL'  => get_admin_plugin_menu_link(NBC_UAM_PATH.'/admin/UserAdvManager_admin.php')
+      'URL'  => get_admin_plugin_menu_link(NBC_UAM_PATH.'/admin/UAM_admin.php')
     )
   );
@@ -63,13 +63,13 @@
 
 /* Lastvisit table feed for Ghost Tracker */
-add_event_handler('loc_begin_index', 'UserAdvManager_GhostTracker');
-
-function UserAdvManager_GhostTracker()
+add_event_handler('loc_begin_index', 'UAM_GhostTracker');
+
+function UAM_GhostTracker()
 {
   global $conf, $user;
-  
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
-
-  if (isset($conf_nbc_UserAdvManager[17]) and $conf_nbc_UserAdvManager[17] == 'true' and !is_admin() and !is_a_guest())
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
+
+  if (isset($conf_UAM[17]) and $conf_UAM[17] == 'true' and !is_admin() and !is_a_guest())
   {
 
@@ -110,14 +110,14 @@
 
 /* User creation */
-add_event_handler('register_user', 'UserAdvManager_Adduser');
-
-function UserAdvManager_Adduser($register_user)
+add_event_handler('register_user', 'UAM_Adduser');
+
+function UAM_Adduser($register_user)
 {
   global $conf;
-  
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
   
   /* Sending registration confirmation by email */
-  if ((isset($conf_nbc_UserAdvManager[0]) and $conf_nbc_UserAdvManager[0] == 'true' and !is_admin()) or (isset($conf_nbc_UserAdvManager[2]) and $conf_nbc_UserAdvManager[2] == 'true' and !is_admin()))
+  if ((isset($conf_UAM[0]) and $conf_UAM[0] == 'true' and !is_admin()) or (isset($conf_UAM[2]) and $conf_UAM[2] == 'true' and !is_admin()))
   {
     $passwd = (isset($_POST['password'])) ? $_POST['password'] : '';
@@ -129,7 +129,7 @@
 
 /* User deletion */
-add_event_handler('delete_user', 'UserAdvManager_Deluser');
-
-function UserAdvManager_Deluser($user_id)
+add_event_handler('delete_user', 'UAM_Deluser');
+
+function UAM_Deluser($user_id)
 {
   /* Cleanup for ConfirmMail table */
@@ -141,7 +141,7 @@
 
 /* Check users registration */
-add_event_handler('register_user_check', 'UserAdvManager_RegistrationCheck', EVENT_HANDLER_PRIORITY_NEUTRAL, 2);
-
-function UserAdvManager_RegistrationCheck($err, $user)
+add_event_handler('register_user_check', 'UAM_RegistrationCheck', EVENT_HANDLER_PRIORITY_NEUTRAL, 2);
+
+function UAM_RegistrationCheck($err, $user)
 {
   global $errors, $conf;
@@ -227,9 +227,9 @@
 /* ****************************************** */
   $PasswordCheck = 0;
-  
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
   /* Password enforcement control */
-  if (isset($conf_nbc_UserAdvManager[14]) and $conf_nbc_UserAdvManager[14] == 'true' and !empty($conf_nbc_UserAdvManager[15]))
+  if (isset($conf_UAM[14]) and $conf_UAM[14] == 'true' and !empty($conf_UAM[15]))
   {
     if (!empty($user['password']) and !is_admin())
@@ -237,18 +237,18 @@
       $PasswordCheck = testpassword($user['password']);
   
-      if ($PasswordCheck < $conf_nbc_UserAdvManager[15])
+      if ($PasswordCheck < $conf_UAM[15])
       {
         $message = get_l10n_args('reg_err_login4_%s', $PasswordCheck);
-        return($lang['reg_err_pass'] = l10n_args($message).$conf_nbc_UserAdvManager[15]);
-      }
-    }
-    else if (!empty($user['password']) and is_admin() and isset($conf_nbc_UserAdvManager[16]) and $conf_nbc_UserAdvManager[16] == 'true')
+        return($lang['reg_err_pass'] = l10n_args($message).$conf_UAM[15]);
+      }
+    }
+    else if (!empty($user['password']) and is_admin() and isset($conf_UAM[16]) and $conf_UAM[16] == 'true')
     { 
       $PasswordCheck = testpassword($user['password']);
   
-      if ($PasswordCheck < $conf_nbc_UserAdvManager[15])
+      if ($PasswordCheck < $conf_UAM[15])
       {
         $message = get_l10n_args('reg_err_login4_%s', $PasswordCheck);
-        return($lang['reg_err_pass'] = l10n_args($message).$conf_nbc_UserAdvManager[15]);
+        return($lang['reg_err_pass'] = l10n_args($message).$conf_UAM[15]);
       }
     }
@@ -256,5 +256,5 @@
 
   /* Username non case sensitive */
-  if (isset($conf_nbc_UserAdvManager[1]) and $conf_nbc_UserAdvManager[1] == 'true' and NotSensibleSearchUsername($_POST['login']))
+  if (isset($conf_UAM[1]) and $conf_UAM[1] == 'true' and NotSensibleSearchUsername($_POST['login']))
   {
     return($lang['reg_err_login5'] = l10n('reg_err_login5'));
@@ -262,15 +262,15 @@
 
   /* Username without forbidden keys */
-  if (isset($conf_nbc_UserAdvManager[7]) and $conf_nbc_UserAdvManager[7] == 'true' and !empty($_POST['login']) and ValidateUsername($_POST['login']) and !is_admin())
+  if (isset($conf_UAM[7]) and $conf_UAM[7] == 'true' and !empty($_POST['login']) and ValidateUsername($_POST['login']) and !is_admin())
   {
     $_POST['login'] = '';
-    return($lang['reg_err_login1'] = l10n('reg_err_login6')."'".$conf_nbc_UserAdvManager[8]."'");
+    return($lang['reg_err_login1'] = l10n('reg_err_login6')."'".$conf_UAM[8]."'");
   }
 
   /* Email without forbidden domains */
-  if (isset($conf_nbc_UserAdvManager[12]) and $conf_nbc_UserAdvManager[12] == 'true' and !empty($_POST['mail_address']) and ValidateEmailProvider($_POST['mail_address']) and !is_admin())
+  if (isset($conf_UAM[12]) and $conf_UAM[12] == 'true' and !empty($_POST['mail_address']) and ValidateEmailProvider($_POST['mail_address']) and !is_admin())
   {
     $_POST['mail_address'] = '';
-    return($lang['reg_err_login1'] = l10n('reg_err_login7')."'".$conf_nbc_UserAdvManager[13]."'");
+    return($lang['reg_err_login1'] = l10n('reg_err_login7')."'".$conf_UAM[13]."'");
   }
 }
@@ -279,20 +279,20 @@
 if (script_basename() == 'profile')
 {
-  add_event_handler('loc_begin_profile', 'UserAdvManager_Profile_Init');
-
-  function UserAdvManager_Profile_Init()
+  add_event_handler('loc_begin_profile', 'UAM_Profile_Init');
+
+  function UAM_Profile_Init()
   {
     global $conf, $user, $template;
 
-    $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+    $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
     if (isset($_POST['validate']) and !is_admin())
     {
       /* Email without forbidden domains */
-      if (isset($conf_nbc_UserAdvManager[12]) and $conf_nbc_UserAdvManager[12] == 'true' and !empty($_POST['mail_address']))
+      if (isset($conf_UAM[12]) and $conf_UAM[12] == 'true' and !empty($_POST['mail_address']))
       {
         if (ValidateEmailProvider($_POST['mail_address']))
         {
-          $template->append('errors', l10n('reg_err_login7')."'".$conf_nbc_UserAdvManager[13]."'");
+          $template->append('errors', l10n('reg_err_login7')."'".$conf_UAM[13]."'");
           unset($_POST['validate']);
         }
@@ -306,12 +306,12 @@
         
         /* Password enforcement control */
-        if (isset($conf_nbc_UserAdvManager[14]) and $conf_nbc_UserAdvManager[14] == 'true' and !empty($conf_nbc_UserAdvManager[15]))
+        if (isset($conf_UAM[14]) and $conf_UAM[14] == 'true' and !empty($conf_UAM[15]))
         {
           $PasswordCheck = testpassword($_POST['use_new_pwd']);
          
-          if ($PasswordCheck < $conf_nbc_UserAdvManager[15])
+          if ($PasswordCheck < $conf_UAM[15])
           {
             $message = get_l10n_args('reg_err_login4_%s', $PasswordCheck);
-            $template->append('errors', l10n_args($message).$conf_nbc_UserAdvManager[15]);
+            $template->append('errors', l10n_args($message).$conf_UAM[15]);
             unset($_POST['use_new_pwd']);
             unset($_POST['validate']);
@@ -321,5 +321,5 @@
       
       /* Sending registration confirmation by email */
-      if ((isset($conf_nbc_UserAdvManager[0]) and $conf_nbc_UserAdvManager[0] == 'true') or (isset($conf_nbc_UserAdvManager[2]) and $conf_nbc_UserAdvManager[2] == 'true'))
+      if ((isset($conf_UAM[0]) and $conf_UAM[0] == 'true') or (isset($conf_UAM[2]) and $conf_UAM[2] == 'true'))
       {
         $confirm_mail_need = false;
@@ -335,10 +335,10 @@
           list($current_email) = mysql_fetch_row(pwg_query($query));
       
-          if ($_POST['mail_address'] != $current_email and ( isset($conf_nbc_UserAdvManager[2]) and $conf_nbc_UserAdvManager[2] == 'true'))
+          if ($_POST['mail_address'] != $current_email and ( isset($conf_UAM[2]) and $conf_UAM[2] == 'true'))
         
             $confirm_mail_need = true;
         }
         
-        if ((!empty($_POST['use_new_pwd']) and (isset($conf_nbc_UserAdvManager[0]) and $conf_nbc_UserAdvManager[0] == 'true') or $confirm_mail_need))
+        if ((!empty($_POST['use_new_pwd']) and (isset($conf_UAM[0]) and $conf_UAM[0] == 'true') or $confirm_mail_need))
         {
           $query = '
@@ -358,12 +358,12 @@
 
 
-add_event_handler('init', 'UserAdvManager_InitPage');
+add_event_handler('init', 'UAM_InitPage');
 /* *** Important ! This is necessary to make email exclusion work in admin's users management panel *** */
-function UserAdvManager_InitPage()
+function UAM_InitPage()
 {
   load_language('plugin.lang', NBC_UAM_PATH);
   global $conf, $template, $page, $lang, $errors;
 
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 /* Admin user management */
@@ -373,7 +373,7 @@
     {
       /* Email without forbidden domains */
-      if (isset($conf_nbc_UserAdvManager[12]) and $conf_nbc_UserAdvManager[12] == 'true' and !empty($_POST['email']) and ValidateEmailProvider($_POST['email']))
-      {
-        $template->append('errors', l10n('reg_err_login7')."'".$conf_nbc_UserAdvManager[13]."'");
+      if (isset($conf_UAM[12]) and $conf_UAM[12] == 'true' and !empty($_POST['email']) and ValidateEmailProvider($_POST['email']))
+      {
+        $template->append('errors', l10n('reg_err_login7')."'".$conf_UAM[13]."'");
         unset($_POST['submit_add']);
       }
@@ -383,19 +383,19 @@
 
 
-add_event_handler('user_comment_check', 'UserAdvManager_CheckEmptyCommentAuthor', 50, 2);
-
-function UserAdvManager_CheckEmptyCommentAuthor($comment_action, $comm)
+add_event_handler('user_comment_check', 'UAM_CheckEmptyCommentAuthor', 50, 2);
+
+function UAM_CheckEmptyCommentAuthor($comment_action, $comm)
 {
   load_language('plugin.lang', NBC_UAM_PATH);
   global $infos, $conf, $template;
 
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+  $conf_UAM = unserialize($conf['nbc_UserAdvManager']);
 
 /* User creation OR update */
-  if (isset($conf_nbc_UserAdvManager[6]) and $conf_nbc_UserAdvManager[6] == 'true' and $conf['comments_forall'] == 'true' and $comm['author'] == 'guest')
+  if (isset($conf_UAM[6]) and $conf_UAM[6] == 'true' and $conf['comments_forall'] == 'true' and $comm['author'] == 'guest')
   {
     $comment_action = 'reject';
 
-    array_push($infos, l10n('UserAdvManager_Empty Author'));
+    array_push($infos, l10n('UAM_Empty Author'));
   }
 
Index: /extensions/NBC_UserAdvManager/trunk/maintain.inc.php
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/maintain.inc.php	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/maintain.inc.php	(revision 5056)
@@ -2,7 +2,10 @@
 
 if(!defined("NBC_UAM_PATH")) define('NBC_UAM_PATH' , PHPWG_PLUGINS_PATH.basename(dirname(__FILE__)).'/');
+if (!defined('NBC_UAM_ROOT')) {
+  define('NBC_UAM_ROOT',     dirname(__FILE__).'/');
+}
 
 include_once (NBC_UAM_PATH.'include/constants.php');
-include_once (NBC_UAM_PATH.'include/functions_UserAdvManager.inc.php');
+include_once (NBC_UAM_PATH.'include/functions.inc.php');
 
 function plugin_install()
@@ -10,6 +13,22 @@
 	global $conf;
 	
+  $default1 = array('false','false','false',-1,-1,-1,'false','false','',-1,'','','false','','false',100,'false','false',10,'Hello.
+	
+This is a reminder because a very long time passed since your last visit on our gallery. If you do not want anymore to use your access account, please let us know by replying to this email. Your account will be deleted.
+
+On receipt of this message and no new visit within 15 days, we would be obliged to automatically delete your account.
+
+Best regards,
+
+The admin of the gallery.','false');
+
   $q = '
 INSERT INTO '.CONFIG_TABLE.' (param, value, comment)
+VALUES ("nbc_UserAdvManager","'.addslashes(serialize($default1)).'","NBC_UAM parameters")
+  ;';
+  pwg_query($q);
+  
+/*  $q = '
+INSERT INTO '.CONFIG_TABLE.' (param, value, comment)
 VALUES ("nbc_UserAdvManager","false;false;false;-1;-1;-1;false;false;;-1;;;false;;false;100;false;false;10;Hello.
 	
@@ -22,8 +41,25 @@
 The admin of the gallery.;false","Parametres du plugin nbc UserAdvManager")
   ;';
-  pwg_query($q);
+  pwg_query($q);*/
+
+  $default2 = array('false',5,'Hello.
+		
+This is a reminder message because you registered on our gallery but you do not validate your registration and your validation key has expired. To still allow you to access to our gallery, your validation period has been reset. You have again 5 days to validate your registration.
+
+Note: After this period, your account will be permanently deleted.','false','Hello.
+
+This is a reminder message because you registered on our gallery but you do not validate your registration and your validation key will expire. To allow you access to our gallery, you have 2 days to confirm your registration by clicking on the link in the message you should have received when you registered.
+
+Note: After this period, your account will be permanently deleted.');
 
   $q = '
 INSERT INTO '.CONFIG_TABLE.' (param, value, comment)
+VALUES ("nbc_UserAdvManager_ConfirmMail","'.addslashes(serialize($default2)).'","NBC_UAM ConfirmMail parameters")
+  ;';
+  pwg_query($q);
+
+
+/*  $q = '
+INSERT INTO '.CONFIG_TABLE.' (param, value, comment)
 VALUES ("nbc_UserAdvManager_ConfirmMail","false;5;Hello.
 		
@@ -36,5 +72,5 @@
 Note: After this period, your account will be permanently deleted.","Parametres nbc_UserAdvManager - ConfirmMail")
   ;';
-  pwg_query($q);
+  pwg_query($q);*/
 
 	$q = "
@@ -65,8 +101,9 @@
 {
 	  global $conf;
-    
+
 /* Cleaning obsolete files */
     update_files($plugin_id);
-	
+
+
 /* Check for upgrade from 2.10 to 2.11 */
 	  $query = '
@@ -107,4 +144,30 @@
     upgrade_212();
   }
+
+
+/* Serializing conf parameters - Available since 2.13.5 */
+  if (unserialize($conf['nbc_UserAdvManager']) === false)
+  {
+    $data = explode(';', $conf['nbc_UserAdvManager']);
+
+    $query = '
+UPDATE '.CONFIG_TABLE.'
+  SET value = "'.addslashes(serialize($data)).'"
+  WHERE param = "nbc_UserAdvManager"
+;';
+    pwg_query($query);
+  }
+  
+  if (unserialize($conf['nbc_UserAdvManager_ConfirmMail']) === false)
+  {
+    $data = explode(';', $conf['nbc_UserAdvManager_ConfirmMail']);
+
+    $query = '
+UPDATE '.CONFIG_TABLE.'
+  SET value = "'.addslashes(serialize($data)).'"
+  WHERE param = "nbc_UserAdvManager_ConfirmMail"
+;';
+    pwg_query($query);
+  }
 }
 
@@ -170,9 +233,9 @@
 	global $conf;
 
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
-
-  if ((!isset($conf_nbc_UserAdvManager[14]) and !isset($conf_nbc_UserAdvManager[15])) and !isset($conf_nbc_UserAdvManager[16]) and !isset($conf_nbc_UserAdvManager[17]))
-  {
-    $upgrade_nbc_UserAdvManager = $conf_nbc_UserAdvManager[0].';'.$conf_nbc_UserAdvManager[1].';'.$conf_nbc_UserAdvManager[2].';'.$conf_nbc_UserAdvManager[3].';'.$conf_nbc_UserAdvManager[4].';'.$conf_nbc_UserAdvManager[5].';'.$conf_nbc_UserAdvManager[6].';'.$conf_nbc_UserAdvManager[7].';'.$conf_nbc_UserAdvManager[8].';'.$conf_nbc_UserAdvManager[9].';'.$conf_nbc_UserAdvManager[10].';'.$conf_nbc_UserAdvManager[11].';'.$conf_nbc_UserAdvManager[12].';'.$conf_nbc_UserAdvManager[13].';false;100;false;false;10;Hello.
+  $conf_UAM = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+
+  if ((!isset($conf_UAM[14]) and !isset($conf_UAM[15])) and !isset($conf_UAM[16]) and !isset($conf_UAM[17]))
+  {
+    $upgrade_UAM = $conf_UAM[0].';'.$conf_UAM[1].';'.$conf_UAM[2].';'.$conf_UAM[3].';'.$conf_UAM[4].';'.$conf_UAM[5].';'.$conf_UAM[6].';'.$conf_UAM[7].';'.$conf_UAM[8].';'.$conf_UAM[9].';'.$conf_UAM[10].';'.$conf_UAM[11].';'.$conf_UAM[12].';'.$conf_UAM[13].';false;100;false;false;10;Hello.
 	
 This is a reminder because a very long time passed since your last visit on our gallery. If you do not want anymore to use your access account, please let us know by replying to this email. Your account will be deleted.
@@ -186,5 +249,5 @@
 		$query = '
 UPDATE '.CONFIG_TABLE.'
-SET value="'.$upgrade_nbc_UserAdvManager.'"
+SET value="'.$upgrade_UAM.'"
 WHERE param="nbc_UserAdvManager"
 LIMIT 1
@@ -221,13 +284,13 @@
 	global $conf;
 
-  $conf_nbc_UserAdvManager = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
-
-  if ((!isset($conf_nbc_UserAdvManager[20])))
-  {
-    $upgrade_nbc_UserAdvManager = $conf_nbc_UserAdvManager[0].';'.$conf_nbc_UserAdvManager[1].';'.$conf_nbc_UserAdvManager[2].';'.$conf_nbc_UserAdvManager[3].';'.$conf_nbc_UserAdvManager[4].';'.$conf_nbc_UserAdvManager[5].';'.$conf_nbc_UserAdvManager[6].';'.$conf_nbc_UserAdvManager[7].';'.$conf_nbc_UserAdvManager[8].';'.$conf_nbc_UserAdvManager[9].';'.$conf_nbc_UserAdvManager[10].';'.$conf_nbc_UserAdvManager[11].';'.$conf_nbc_UserAdvManager[12].';'.$conf_nbc_UserAdvManager[13].';'.$conf_nbc_UserAdvManager[14].';'.$conf_nbc_UserAdvManager[15].';'.$conf_nbc_UserAdvManager[16].';'.$conf_nbc_UserAdvManager[17].';'.$conf_nbc_UserAdvManager[18].';'.$conf_nbc_UserAdvManager[19].';false';
+  $conf_UAM = isset($conf['nbc_UserAdvManager']) ? explode(";" , $conf['nbc_UserAdvManager']) : array();
+
+  if ((!isset($conf_UAM[20])))
+  {
+    $upgrade_UAM = $conf_UAM[0].';'.$conf_UAM[1].';'.$conf_UAM[2].';'.$conf_UAM[3].';'.$conf_UAM[4].';'.$conf_UAM[5].';'.$conf_UAM[6].';'.$conf_UAM[7].';'.$conf_UAM[8].';'.$conf_UAM[9].';'.$conf_UAM[10].';'.$conf_UAM[11].';'.$conf_UAM[12].';'.$conf_UAM[13].';'.$conf_UAM[14].';'.$conf_UAM[15].';'.$conf_UAM[16].';'.$conf_UAM[17].';'.$conf_UAM[18].';'.$conf_UAM[19].';false';
 		
 		$query = '
 UPDATE '.CONFIG_TABLE.'
-SET value="'.$upgrade_nbc_UserAdvManager.'"
+SET value="'.$upgrade_UAM.'"
 WHERE param="nbc_UserAdvManager"
 LIMIT 1
Index: /extensions/NBC_UserAdvManager/trunk/obsolete.list
===================================================================
--- /extensions/NBC_UserAdvManager/trunk/obsolete.list	(revision 5055)
+++ /extensions/NBC_UserAdvManager/trunk/obsolete.list	(revision 5056)
@@ -1,2 +1,4 @@
+admin/UserAdvManager_admin.php
 admin/confirmmail.tpl
 admin/UserAdvManager_admin.tpl
+include/functions_UserAdvManager.inc.php
