46 lines
2.7 KiB
PHP
Executable File
46 lines
2.7 KiB
PHP
Executable File
<?php
|
|
$nomFicAppelant = basename(__FILE__);
|
|
include_once("mailer.v04.php");
|
|
include_once ($includePath. "/req/14-init.mailMsgList.php");
|
|
// ---------------------------------------------------
|
|
// Fabrication du message
|
|
// ---------------------------------------------------
|
|
$sujet="Nouveau compte administrateur sur " .$_SESSION['nomSiteAff'];
|
|
$msg='';
|
|
$msg=$msg. "<br>";
|
|
$msg="<img src='" .$mailImgPt[19]. "' alt='" .$mailAlt[19]. "' /><br><br>";
|
|
$msg=$msg. "Chers administrateurs,<br>";
|
|
$msg=$msg. "Une nouveau compte administrateur a été crée sur le site " .$_SESSION['nomSiteAff']. "<br>";
|
|
$msg=$msg. "Voici les informations du compte :<br>";
|
|
$msg=$msg. "Identifiant : $Login";
|
|
$msg=$msg. '<br> --------------------------------- <br>';
|
|
$msg=$msg. "Pour se connecter l'administrateur doit avoir d'abord un compte client.<br>";
|
|
$msg= $msg. '<br><br><a href="' .$prodServer. '/admin/stats/frm.stats.php">Voir les statistiques</a><br><br>';
|
|
$msg=stripslashes($msg);
|
|
|
|
if (isset($debug[1]) && $debug[1] == '1' ) {
|
|
$usrSiteMsg=$usrSiteMsg. 'message_=' .$msg. '<br>';
|
|
$usrSiteMsg=$usrSiteMsg. '<br><span class="debug">validInsc.php => $nbAdmin => ' .$nbAdmin. '</span>';
|
|
}
|
|
|
|
// ---------------------------------------------------
|
|
// Pied de page
|
|
// ---------------------------------------------------
|
|
include ("./mails/pdpAdmin.php");
|
|
$message_business = '<!DOCTYPE html><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>' .$sujet. '</title></head><body>' .$msg. '<br></body></html>';
|
|
if (isset($debug[1]) && $debug[1] == '1' ) {echo 'message_business=' .$message_business. '<br>';}
|
|
|
|
// ---------------------------------------------------
|
|
// Envoi des mails pour chaque admin
|
|
// ---------------------------------------------------
|
|
if (empty($_SESSION['nbAdmin'])) include ($includePath. "/req/15-init.adminMsgList.php");
|
|
for ( $ijk=0 ; $ijk<$_SESSION['nbAdmin'] ; $ijk++) {
|
|
if (isset($debug[1]) && $debug[1] == '1' ) {$usrSiteMsg=$usrSiteMsg. '<br><span class="debug">tableLibAdmin[' .$ijk. ']=' .$tableLibAdmin[$ijk]. ' | tableAdminSms[' .$ijk. ']=' .$tableAdminSms[$ijk]. '</span> <br>';}
|
|
if ($lg=='') {$lg='FRA';}
|
|
if ($tableAdminSms[$ijk]==1) {
|
|
// parametres function mailer($smtpServer, $sujet, $msg, $destinataire1, $destinataire2, $destinataire3, $confirm, $messErr, $messOk, $pieceJointe1_0, $attachPath, $attachName, $expediteur, $fromName, $Var1, $lg)
|
|
$envMail = mailer(1, '','', 0, $_SESSION['smtpServer123'], $sujet,$message_business, $tableLibAdmin[$ijk],'', '', 0, $navMsg[10],$navMsg[23], 0, '', '', $_SESSION['expediteur_mails123'], $_SESSION['from_mails123'], '', $lg);
|
|
}
|
|
}//for nb admin
|
|
?>
|