本文整理汇总了PHP中envoi_mail函数的典型用法代码示例。如果您正苦于以下问题:PHP envoi_mail函数的具体用法?PHP envoi_mail怎么用?PHP envoi_mail使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了envoi_mail函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: add_mbr
function add_mbr($pseudo, $password, $email, $identifier = '', $valide = 0)
{
$bf_token = 'jJ_=éZAç1l';
$ft_token = 'ù%*àè1ç0°dezf';
$key_alea_code_activate = md5(uniqid(mt_rand()));
// Enregistrement de l'utilisateur dans la base de données
Nw::$DB->query('INSERT INTO ' . Nw::$prefix_table . 'members (u_pseudo, u_alias, u_identifier, u_password, u_email, u_group, u_date_register, u_active, u_code_act, u_ip)
VALUES(\'' . insertBD(trim($pseudo)) . '\', \'' . rewrite(trim($pseudo)) . '\', \'' . insertBD(trim($identifier)) . '\', \'' . insertBD(sha1($bf_token . trim($password) . $ft_token)) . '\', \'' . insertBD(trim($email)) . '\',
4, NOW(), ' . intval($valide) . ', \'' . insertBD($key_alea_code_activate) . '\', \'' . get_ip() . '\')') or Nw::$DB->trigger(__LINE__, __FILE__);
$id_new_membre = Nw::$DB->insert_id;
$identifiant_unique = md5($id_new_membre . uniqid(rand(), true));
$lien_activation = Nw::$site_url . 'users-32.html?mid=' . $id_new_membre . '&ca=' . $key_alea_code_activate;
Nw::$DB->query('UPDATE ' . Nw::$prefix_table . 'members SET u_ident_unique = \'' . Nw::$DB->real_escape_string($identifiant_unique) . '\' WHERE u_id = ' . intval($id_new_membre)) or Nw::$DB->trigger(__LINE__, __FILE__);
Nw::$DB->query('INSERT INTO ' . Nw::$prefix_table . 'members_stats (s_id_membre) VALUES(' . intval($id_new_membre) . ')') or Nw::$DB->trigger(__LINE__, __FILE__);
inc_lib('users/mail2gd');
mail2gd($identifiant_unique, trim($email));
inc_lib('newsletter/add_abonnement');
add_abonnement(trim($email), $id_new_membre);
// Envoie d'email de validation
if ($valide == 0) {
$txt_mail = sprintf(Nw::$lang['users']['mail_confirm_insc'], $pseudo, Nw::$site_url, Nw::$site_name, $lien_activation, $lien_activation, $lien_activation);
@envoi_mail(trim($email), sprintf(Nw::$lang['users']['confirm_inscription'], Nw::$site_name), $txt_mail);
} else {
// Le compte est confirmé, on met à jour le nbr de membres
inc_lib('admin/gen_cachefile_nb_members');
gen_cachefile_nb_members();
generate_members_sitemap();
}
return $id_new_membre;
}
示例2: main
/**
* Mot de passe oublié (partie 1)
* @author Cam
* @return tpl
*/
protected function main()
{
// Si le membre est déjà connecté
if (is_logged_in()) {
redir(Nw::$lang['common']['already_connected'], false, './');
}
$this->set_title(Nw::$lang['users']['title_lost_pwd']);
$this->set_tpl('membres/oubli_mdp.html');
$this->add_css('forms.css');
// Fil ariane
$this->set_filAriane(Nw::$lang['users']['title_lost_pwd']);
//Si le formulaire a été validé
if (isset($_POST['submit'])) {
// Cette adresse email existe bien sur le site
inc_lib('users/email_exists');
if (email_exists($_POST['mail'])) {
//On récupère les infos du membre
inc_lib('users/get_info_mbr');
$membre_mail = get_info_mbr($_POST['mail'], 'mail');
$lien_password = Nw::$site_url . 'users-13.html?idm=' . $membre_mail['u_id'] . '&ca=' . $membre_mail['u_code_act'];
//On prépare le texte de l'email
$txt_mail = sprintf(Nw::$lang['users']['mail_oubli_pwd'], $membre_mail['u_pseudo'], $lien_password, $lien_password, $lien_password);
@envoi_mail(trim($_POST['mail']), sprintf(Nw::$lang['users']['title_mail_lost_pwd'], Nw::$site_name), $txt_mail);
redir(Nw::$lang['users']['send_mail_lost'], true, './');
} else {
redir(Nw::$lang['users']['email_aucun_mbr'], false, 'users-12.html');
}
}
}
示例3: validate
function validate($type, $id)
{
$params1 = false;
$params2 = false;
switch ($type) {
case "valider":
$message = ["message" => "Inscription valide"];
$params1 = ['valid' => 1];
$params2 = "validation";
break;
case "refuser":
$message = ["message" => "Inscription refuse"];
$params1 = ['valid' => 2];
$params2 = "refus";
break;
case "supprimer":
$message = ["message" => "Inscription supprimee"];
break;
case "toutsupprimer":
$params2 = "suppression";
break;
}
if ($params1) {
$upd = Config::QueryBuilder()->update('exposants', ['id' => $id], $params1)->execute();
envoi_mail($params2, $id);
} elseif ($params2) {
$upd = Config::QueryBuilder()->deleteAll('exposants')->execute();
} else {
$upd = Config::QueryBuilder()->delete('exposants')->where(['id' => $id])->execute();
}
if ($upd) {
if (!$message) {
$message = ["message" => "Une erreur est survenue merci de contacter un administrateur"];
}
}
$response = json_encode($message);
return $response;
}
示例4:
if((getSettingValue('mode_email_ele')=='mon_compte')) {
$sql="UPDATE eleves SET email='$reg_email' WHERE login='".$_SESSION['login']."';";
$update_eleve=mysqli_query($GLOBALS["mysqli"], $sql);
if(!$update_eleve) {$msg.="<br />Erreur lors de la mise à jour de la table 'eleves'.";}
if((getSettingValue('envoi_mail_actif')!='n')&&(getSettingValue('informer_scolarite_modif_mail')!='n')) {
$sujet_mail=remplace_accents("Mise à jour mail ".$_SESSION['nom']." ".$_SESSION['prenom'],'all');
$message_mail="L'adresse email de l'élève ";
$message_mail.=remplace_accents($_SESSION['nom']." ".$_SESSION['prenom'],'all')." est passée à '$reg_email'. Vous devriez mettre à jour Sconet en conséquence.";
$destinataire_mail=getSettingValue('email_dest_info_modif_mail');
if($destinataire_mail=="") {
$destinataire_mail=getSettingValue('gepiSchoolEmail');
}
$tab_param_mail['destinataire']=$destinataire_mail;
if(($destinataire_mail!='')&&(check_mail($destinataire_mail))) {
envoi_mail($sujet_mail, $message_mail, $destinataire_mail, "", "plain", $tab_param_mail);
}
}
}
}
}
}
}
if ($_SESSION['statut'] == "scolarite" OR $_SESSION['statut'] == "professeur" OR $_SESSION['statut'] == "cpe")
if ($user_show_email != $reg_show_email) {
if ($reg_show_email != "no" and $reg_show_email != "yes") $reg_show_email = "no";
$reg = mysqli_query($GLOBALS["mysqli"], "UPDATE utilisateurs SET show_email = '$reg_show_email' WHERE login = '" . $_SESSION['login'] . "'");
if ($reg) {
if($msg!="") {$msg.="<br />";}
示例5: preg_replace
if ($destinataires != "") {
$texte_mail = $texte_mail . "\n\n" . "Message: " . preg_replace('#<br />#', "\n", $msg);
$subject = "[GEPI][" . ucfirst($mod_disc_terme_incident) . " n°{$id_incident}]" . $info_classe_prot . $liste_protagonistes_responsables;
$headers = "";
if (isset($_SESSION['email']) && check_mail($_SESSION['email'])) {
$headers .= "Reply-to:" . $_SESSION['email'] . "\r\n";
$tab_param_mail['replyto'] = $_SESSION['email'];
}
if (isset($message_id)) {
$headers .= "Message-id: {$message_id}\r\n";
}
if (isset($references_mail)) {
$headers .= "References: {$references_mail}\r\n";
}
// On envoie le mail
$envoi = envoi_mail($subject, $texte_mail, $destinataires, $headers, "plain", $tab_param_mail);
}
}
}
}
}
}
}
}
//$utilisation_scriptaculous="y";
//$utilisation_jsdivdrag='non';
//$javascript_specifique[]="lib/prototype";
$javascript_specifique[] = "lib/scriptaculous";
$javascript_specifique[] = "lib/unittest";
$javascript_specifique[] = "lib/effects";
$javascript_specifique[] = "lib/controls";
示例6: price2num
}
print "Unpaid invoice " . $obj->facnumber . ", price " . price2num($obj->total_ttc) . ", due date " . dol_print_date($db->jdate($obj->due_date), 'day') . " (linked to company " . $obj->name . ", sale representative " . dolGetFirstLastname($obj->firstname, $obj->lastname) . ", email " . $obj->email . ", lang " . $outputlangs->defaultlang . "): ";
if (dol_strlen($obj->email)) {
print "qualified.";
} else {
print "disqualified (no email).";
}
print "\n";
unset($outputlangs);
$total += $obj->total_ttc;
$i++;
}
// Si il reste des envois en buffer
if ($foundtoprocess) {
if (dol_strlen($oldemail) && $oldemail != 'none') {
envoi_mail($mode, $oldemail, $message, $total, $oldlang, $oldsalerepresentative);
} else {
if ($oldemail != 'none') {
print "- No email sent for " . $oldsalerepresentative . ", total: " . $total . "\n";
}
}
}
} else {
print "No unpaid invoices (for companies linked to a particular commercial dolibarr user) found\n";
}
exit(0);
} else {
dol_print_error($db);
dol_syslog("email_unpaid_invoices_to_representatives.php: Error");
exit(-1);
}
示例7: pg_query
$result = pg_query($db, $query) or die("Erreur pgSQL : " . pg_result_error($result));
$row = pg_fetch_array($result);
$message_html = msg_pw($row);
envoi_mail($row['email'], $sujet, $message_html, "");
} elseif (strlen($select) > 0) {
$pairs = explode("&", $select);
foreach ($pairs as $key => $value) {
$id = ltrim($value, "id=");
$where .= "a.id_user='" . $id . "' OR ";
}
$where = rtrim($where, "OR ");
$query = "SELECT a.id_user, lib_cbn, nom, prenom, login, pw, tel_bur, tel_port, email, web, descr, aze.lr,qsd.eee,wxc.refnat,zer.catnat,sdf.lsi,xcv.fsd,ref_lr, ref_eee, ref_lsi, ref_catnat, ref_refnat,ref_fsd\n\t\t\tFROM applications.utilisateur a\n\t\t\tJOIN referentiels.cbn z ON a.id_cbn = z.id_cbn\n\t\t\tJOIN (SELECT id_user, lib as lr FROM applications.utilisateur a JOIN referentiels.user_ref z ON niveau_lr = cd) as aze ON aze.id_user = a.id_user\n\t\t\tJOIN (SELECT id_user, lib as eee FROM applications.utilisateur a JOIN referentiels.user_ref z ON niveau_eee = cd) as qsd ON qsd.id_user = a.id_user\n\t\t\tJOIN (SELECT id_user, lib as refnat FROM applications.utilisateur a JOIN referentiels.user_ref z ON niveau_refnat = cd) as wxc ON wxc.id_user = a.id_user\n\t\t\tJOIN (SELECT id_user, lib as catnat FROM applications.utilisateur a JOIN referentiels.user_ref z ON niveau_catnat = cd) as zer ON zer.id_user = a.id_user\n\t\t\tJOIN (SELECT id_user, lib as lsi FROM applications.utilisateur a JOIN referentiels.user_ref z ON niveau_lsi = cd) as sdf ON sdf.id_user = a.id_user\n\t\t\tJOIN (SELECT id_user, lib as fsd FROM applications.utilisateur a JOIN referentiels.user_ref z ON niveau_fsd = cd) as xcv ON xcv.id_user = a.id_user\n\t\t\tWHERE {$where};\n\t\t\t";
$result = pg_query($db, $query) or die("Erreur pgSQL : " . pg_result_error($result));
while ($row = pg_fetch_array($result)) {
$message_html = msg_pw($row);
envoi_mail($row['email'], $sujet, $message_html, "");
}
}
break;
}
echo "</div>";
//------------------------------------------------------------------------------
echo "</div>";
echo "</div>";
echo "<br /></div>";
echo "<div></body></html>";
pg_close($db);
//------------------------------------------------------------------------------ SI PAS ACCES
} else {
require "../commun/access_denied.php";
}
示例8: action_alea_invalide
/**
* Actions en cas d'attaque CSRF
*
* Construit un message à envoyé à l'administrateur et à enregistrer dans les logs
*
* @param bool $envoyer_mail Un courriel est envoyé à l'administrateur si TRUE
* @see getSettingValue()
* @see envoi_mail()
*/
function action_alea_invalide($envoyer_mail=TRUE) {
// NE pas donner dans le mail les valeurs du token pour éviter des problèmes lors d'une éventuelle capture du mail.
$details="La personne victime de l'attaque était ".$_SESSION['login'].".\n";
$details.="La page cible était ".$_SERVER['PHP_SELF']." avec les variables suivantes:\n";
$details.="Variables en \$_POST:\n";
foreach($_POST as $key => $value) {
$details.=" \$_POST[$key]=$value\n";
}
$details.="Variables en \$_GET:\n";
foreach($_GET as $key => $value) {
$details.=" \$_GET[$key]=$value\n";
}
if($envoyer_mail) {
// Envoyer un mail à l'admin
$envoi_mail_actif=getSettingValue('envoi_mail_actif');
if($envoi_mail_actif!="n") {
$destinataire=getSettingValue('gepiAdminAdress');
if($destinataire!='') {
$sujet="Attaque CSRF";
$message="La variable csrf_alea ne coincide pas avec le gepi_alea en SESSION.\n";
$message.=$details;
envoi_mail($sujet, $message,$destinataire);
}
}
}
if(getSettingValue('csrf_log')=='y') {
$csrf_log_chemin=getSettingValue('csrf_log_chemin');
if($csrf_log_chemin=='') {$csrf_log_chemin="/home/root/csrf";}
$f=fopen("$csrf_log_chemin/csrf_".$_SESSION['login'].".log","a+");
fwrite($f,"Alerte CSRF ".strftime("%a %d/%m/%Y %H:%M:%S")." avec\n");
fwrite($f,"\$_SESSION['gepi_alea']=".$_SESSION['gepi_alea']."\n");
fwrite($f,$details."\n");
fwrite($f,"================================================\n");
fclose($f);
}
}
示例9: envoi_mail
<?php
require $_SERVER['DOCUMENT_ROOT'] . '/BiellesMeusiennes/BiellesMeusiennes/vendor/autoload.php';
include_once $_SERVER['DOCUMENT_ROOT'] . '/BiellesMeusiennes/BiellesMeusiennes/includes/common/functions.php';
include_once $_SERVER['DOCUMENT_ROOT'] . '/BiellesMeusiennes/BiellesMeusiennes/includes/common/mailing.php';
use Core\Mailer\Mail;
use Core\Configure\Config;
use Core\Export\DataExporter;
envoi_mail("inscription", "adresse_mail_inscrit@localhost.io", 83);
envoi_mail("nouvel_inscrit", "mail_admin@localhost.io", 83);
envoi_mail("validation", "adresse_mail_inscrit@localhost.io", 83);
envoi_mail("refus", "adresse_mail_inscrit@localhost.io", 83);
示例10: retourne_email
$ajout_headers = "";
$email_utilisateur = retourne_email($_SESSION['login']);
if ($email_utilisateur != '') {
$ajout_headers = "Reply-to: {$email_utilisateur}";
$tab_param_mail['replyto'] = $email_utilisateur;
}
// On considère que le signalement est un succès, si le mail est envoyé pour au moins un destinataire
$temoin = false;
$temoin2 = true;
while ($lig = mysqli_fetch_object($res)) {
if ($envoi_mail_actif != 'n' && check_mail($lig->email)) {
$destinataire = $lig->email;
$tab_param_mail['destinataire'] = $destinataire;
$sujet = "[GEPI]: Signalement par " . casse_mot($_SESSION['prenom'], 'majf2') . " " . $_SESSION['nom'];
//if(envoi_mail($sujet, nl2br($signalement_message), $destinataire, $ajout_headers)) {$temoin=true;}
if (envoi_mail($sujet, $signalement_message, $destinataire, $ajout_headers, "plain", $tab_param_mail)) {
$temoin = true;
}
}
// On dépose un message en page d'accueil:
$statuts_destinataires = "_";
// Deux semaines d'affichage
$date_debut = time();
$date_fin = $date_debut + 2 * 7 * 24 * 3600;
$date_decompte = $date_fin;
$contenu_cor = "<strong>Signalement par " . casse_mot($_SESSION['prenom'], 'majf2') . " " . $_SESSION['nom'] . "</strong><br />" . mysqli_real_escape_string($GLOBALS['mysqli'], nl2br($signalement_message));
if (!set_message($contenu_cor, $date_debut, $date_fin, $date_decompte, $statuts_destinataires, $lig->login)) {
$temoin2 = false;
}
}
if ($temoin && $temoin2) {
示例11: getSettingValue
}
}
}
$saut = 1;
$nb_fiches = getSettingValue("ImpressionNombreParent");
$tab_envoi_reussi = array();
foreach ($tab_classe_parent as $classe => $tab_parent) {
/*
echo "<pre>";
print_r($tab_parent);
echo "</pre>";
*/
for ($loop = 0; $loop < count($tab_parent); $loop++) {
$chaine = "<table>\n\t<tr>\n\t\t<th style='text-align:left;'>A l'attention de </th>\n\t\t<th>: </th>\n\t\t<td>" . $tab_parent[$loop]['nom_prenom'] . "</td>\n\t</tr>\n\t<tr>\n\t\t<th style='text-align:left;'>Login ENT</th>\n\t\t<th>: </th>\n\t\t<td>" . $tab_parent[$loop]['login_ent'] . "</td>\n\t</tr>\n\t<tr>\n\t\t<th style='text-align:left;'>Mot de passe ENT</th>\n\t\t<th>: </th>\n\t\t<td>" . $tab_parent[$loop]['mdp_ent'] . "</td>\n\t</tr>\n\t<tr>\n\t\t<th style='text-align:left;'>Email ENT</th>\n\t\t<th>: </th>\n\t\t<td>" . $tab_parent[$loop]['email_ent'] . "</td>\n\t</tr>\n\t<tr>\n\t\t<th style='text-align:left; vertical-align:top;'>Adresse</th>\n\t\t<th style='vertical-align:top;'>: </th>\n\t\t<td>" . $tab_parent[$loop]['adresse'] . "</td>\n\t</tr>\n\t<tr>\n\t\t<th style='text-align:left;'>Responsable notamment de</th>\n\t\t<th>: </th>\n\t\t<td>" . $tab_parent[$loop]['resp_de'] . "</td>\n\t</tr>\n</table>\n{$impression}";
$tab_param_mail['destinataire'] = $tab_parent[$loop]['email_gepi'];
if (isset($tab_parent[$loop]['email_gepi']) && ($envoi = envoi_mail("Compte Gepi", "Bonjour(soir),\n" . $chaine, $tab_parent[$loop]['email_gepi'], "", "html", $tab_param_mail))) {
$tab_envoi_reussi[] = $tab_parent[$loop]['nom_prenom'] . " (" . $tab_parent[$loop]['email_gepi'] . ") parent de " . $tab_parent[$loop]['resp_de'];
} else {
echo $chaine . "";
// Saut de page toutes les $nb_fiches fiches
if ($saut == $nb_fiches) {
echo "<p class='saut'> </p>\n";
$saut = 1;
} else {
$saut++;
}
echo "<hr class='noprint'/>";
}
flush();
}
}
示例12: price2num
}
print "Unpaid invoice " . $obj->facnumber . ", price " . price2num($obj->total_ttc) . ", due date " . dol_print_date($db->jdate($obj->due_date), 'day') . ", customer id " . $obj->sid . " " . $obj->name . ", " . ($obj->cid ? "contact id " . $obj->cid . " " . $obj->clastname . " " . $obj->cfirstname . ", " : "") . "email " . $newemail . ", lang " . $outputlangs->defaultlang . ": ";
if (dol_strlen($newemail)) {
print "qualified.";
} else {
print "disqualified (no email).";
}
print "\n";
unset($outputlangs);
$total += $obj->total_ttc;
$i++;
}
// Si il reste des envois en buffer
if ($foundtoprocess) {
if (dol_strlen($oldemail) && $oldemail != 'none' && empty($trackthirdpartiessent[$oldsid . '|' . $oldemail])) {
envoi_mail($mode, $oldemail, $message, $total, $oldlang, $oldtarget);
$trackthirdpartiessent[$oldsid . '|' . $oldemail] = 'contact id ' . $oldcid;
} else {
if ($oldemail != 'none') {
if (empty($trackthirdpartiessent[$oldsid . '|' . $oldemail])) {
print "- No email sent for '" . $oldtarget . "', total: " . $total . "\n";
} else {
print "- No email sent for '" . $oldtarget . "', total: " . $total . " (already sent to " . $trackthirdpartiessent[$oldsid . '|' . $oldemail] . ")\n";
}
}
}
}
} else {
print "No unpaid invoices found\n";
}
exit(0);
示例13: dol_concatdesc
}
print "Service to expire " . $obj->ref . ", label " . dol_concatdesc($obj->plabel, $obj->description) . ", due date " . dol_print_date($db->jdate($obj->date_fin_validite), 'day') . ", customer id " . $obj->sid . " " . $obj->name . ", " . ($obj->cid ? "contact id " . $obj->cid . " " . $obj->clastname . " " . $obj->cfirstname . ", " : "") . "email " . $newemail . ", lang " . $outputlangs->defaultlang . ": ";
if (dol_strlen($newemail)) {
print "qualified.";
} else {
print "disqualified (no email).";
}
print "\n";
unset($outputlangs);
$total += $obj->total_ttc;
$i++;
}
// Si il reste des envois en buffer
if ($foundtoprocess) {
if (dol_strlen($oldemail) && $oldemail != 'none' && empty($trackthirdpartiessent[$oldsid . '|' . $oldemail])) {
envoi_mail($mode, $oldemail, $message, $total, $oldlang, $oldtarget, $duration_value);
$trackthirdpartiessent[$oldsid . '|' . $oldemail] = 'contact id ' . $oldcid;
} else {
if ($oldemail != 'none') {
if (empty($trackthirdpartiessent[$oldsid . '|' . $oldemail])) {
print "- No email sent for '" . $oldtarget . "', total: " . $total . "\n";
} else {
print "- No email sent for '" . $oldtarget . "', total: " . $total . " (already sent to " . $trackthirdpartiessent[$oldsid . '|' . $oldemail] . ")\n";
}
}
}
}
} else {
print "No services to expire found\n";
}
exit(0);
示例14: json_decode
$client_id = $db->lastInsertId();
$info_analyse2 = json_decode($info_analyse);
$info_radio2 = json_decode($info_radio);
$filename = '../sauvegarde/animaux/' . $_POST['animal_id'];
$info_acte2 = json_decode($info_acte, TRUE);
$info_medic2 = json_decode($info_medic, TRUE);
if ($_POST['veto_ref_mail'] != '') {
if (count($info_analyse2) > 0 && count($info_radio2) > 0) {
// envoi_mail2($_POST['veto_ref_mail'], $_POST['veto_ref'], $info_client[0]['nom'], $info_animal[0]['nom_a'], $info_formulaire['date_consultation'], $info_formulaire['barre_resume'], $clinique, $info_acte2, $info_medic2,$_POST['consultation_id'],1,1, $nom_serveur_mail, $mail_serveur, $filename,$db);
envoi_mail2($_POST['veto_ref_mail'], $_POST['veto_ref'], $info_client[0], $info_animal[0]['nom_a'], $info_formulaire['date_consultation'], $info_formulaire['barre_resume'], $clinique, $info_acte2, $info_medic2, $_POST['consultation_id'], 1, 1, $nom_serveur_mail, $mail_serveur, $filename, $db);
} elseif (count($info_analyse2) == 0 && count($info_radio2) > 0) {
envoi_mail2($_POST['veto_ref_mail'], $_POST['veto_ref'], $info_client[0], $info_animal[0]['nom_a'], $info_formulaire['date_consultation'], $info_formulaire['barre_resume'], $clinique, $info_acte2, $info_medic2, $_POST['consultation_id'], 0, 1, $nom_serveur_mail, $mail_serveur, $filename, $db);
} elseif (count($info_analyse2) > 0 && count($info_radio2) == 0) {
envoi_mail2($_POST['veto_ref_mail'], $_POST['veto_ref'], $info_client[0], $info_animal[0]['nom_a'], $info_formulaire['date_consultation'], $info_formulaire['barre_resume'], $clinique, $info_acte2, $info_medic2, $_POST['consultation_id'], 1, 0, $nom_serveur_mail, $mail_serveur, $filename, $db);
} else {
envoi_mail($_POST['veto_ref_mail'], $_POST['veto_ref'], $info_client[0], $info_animal[0]['nom_a'], $info_formulaire['date_consultation'], $info_formulaire['barre_resume'], $clinique, $info_acte2, $info_medic2, $_POST['consultation_id'], $nom_serveur_mail, $mail_serveur, $db);
}
}
echo json_encode($client_id);
} elseif ($_GET['action'] == 'mur') {
$nom_client = $_POST['client'];
$nom_animal = $_POST['animal'];
$importance = $_POST['importance'];
$ma_var = $_POST['client'] . ' ' . $_POST['animal'];
$st = $db->prepare("INSERT INTO `aerogard2`.`liste_mur` (`id` ,`texte` ,`importance` ,`permission`) VALUES ('' , ?, ?, ?);");
$st->bindParam(1, $ma_var);
$st->bindParam(2, $importance);
$st->bindParam(3, $_SESSION['login']);
$st->execute();
$id_liste_mur = $db->lastInsertId();
echo json_encode($id_liste_mur);
示例15: envoi_mail
if((isset($_POST['envoi_mail']))&&(check_mail($user_email))) {
$tab_param_mail['destinataire']=$user_email;
$texte_email="A l'attention de $user_prenom $user_nom<br />\n";
$texte_email.="Identifiant : $user_login<br />\n";
if(isset($new_password)) {
$texte_email.="Mot de passe : $new_password<br />\n";
}
$texte_email.=$impression;
$sujet_mail = "[GEPI] Compte Gepi";
$headers = "";
// On envoie le mail
$envoi = envoi_mail($sujet_mail, $texte_email, $user_email, $headers, "html", $tab_param_mail);
if($envoi) {
echo "<div style='float:right; width:5em; text-align:center; color:green;' class='fieldset_opacite50 noprint'>Mail envoyé</div>";
}
else {
echo "<div style='float:right; width:5em; text-align:center; color:red;' class='fieldset_opacite50 noprint'>Echec de l'envoi du mail</div>";
}
}
}
/*
// Bloc adresse responsable
$addressblock_padding_right,
$addressblock_padding_top,
$addressblock_padding_text,
$addressblock_length,