IsSMTP(); $mail->Host="server119.neubox.net"; $mail->SMTPDebug=1; $mail->SMTPAuth=true; $mail->SMTPSecure="ssl"; $mail->Port=465; $mail->Username=$email_remitente; $mail->Password=$password_remitente; $mail->AddReplyTo($email_remitente); $mail->AddAddress($destinatario); //Buscar todos los usuarios que puedan recibir copia $c_us=buscar("email","adm_usuarios","WHERE recibir_copia='si' AND estatus='activo'"); while($f_us=mysql_fetch_assoc($c_us)): $email=$f_us['email']; if(!empty($email)): $mail->AddBCC($email); endif; unset($email); endwhile; $mail->SetFrom($email_remitente); if($p_id==1): $asunto1="Reservación de stand ANAFAPYT LATIN AMERICAN COATINGS SHOW®!"; else: $asunto1="Booking of Stand ANAFAPYT LATIN AMERICAN COATINGS SHOW®!"; endif; $mail->Subject=$asunto1; $mail->From=$email_remitente; $mail->FromName="ANAFAPYT LATIN AMERICAN COATINGS SHOW®"; $mail->Timeout=40; $mensaje1= ' '; if($p_id==1): $mensaje1.=' '; if(!empty($_POST["stand"])): $mensaje1.=' '; endif; if(!empty($_POST["mensaje"])): $mensaje1.=' '; endif; else: $mensaje1.=' '; if(!empty($_POST["stand"])): $mensaje1.=' '; endif; if(!empty($_POST["mensaje"])): $mensaje1.=' '; endif; endif; $mensaje1.='
Reservación: '.sprintf("%05d",$id_reservacion).'
Nombre del expositor: '.$_POST["nombre"].'
Empresa: '.$_POST["empresa"].'
Cargo: '.$_POST["cargo"].'
Lada/Teléfono: '.$_POST["telefono"].'
Correo electrónico: '.$_POST["email"].'
¿Qué desea reservar? '.$_POST["reservar"].'
Número de stand (sólo para reservación de stand): '.$_POST["stand"].'
Mensaje: '.$_POST["mensaje"].'
Id booking: '.sprintf("%05d",$id_reservacion).'
Exhibitor’s Name: '.$_POST["nombre"].'
Company: '.$_POST["empresa"].'
Position: '.$_POST["cargo"].'
Area Code / Phone Number: '.$_POST["telefono"].'
Email: '.$_POST["email"].'
What you wish to reserve? '.$_POST["reservar"].'
Number of stand (only for booking a stand): '.$_POST["stand"].'
Message: '.$_POST["mensaje"].'
'; $mail->MsgHTML($mensaje1); $mail->IsHTML(true); $mail->CharSet = 'UTF-8'; if($mail->Send()): if(!empty($_POST["email"])): $mail2 = new PHPMailer(true); try { $mail2->IsSMTP(); $mail2->Host="server119.neubox.net"; $mail2->SMTPDebug=1; $mail2->SMTPAuth=true; $mail2->SMTPSecure="ssl"; $mail2->Port=465; $mail2->Username=$email_remitente; $mail2->Password=$password_remitente; $mail2->AddReplyTo($email_remitente); $mail2->AddAddress($_POST["email"]); $mail2->SetFrom($email_remitente); $mail2->IsHTML(true); if($p_id==1): $asunto2="¡Gracias por su reservación a ANAFAPYT LATIN AMERICAN COATINGS SHOW®!"; else: $asunto2="Thank you for booking at ANAFAPYT LATIN AMERICAN COATINGS SHOW®!"; endif; $mail2->Subject =$asunto2; $mail2->From=$email_remitente; $mail2->FromName="ANAFAPYT LATIN AMERICAN COATINGS SHOW®"; $mail2->Timeout=40; $mensaje2= ' '; if($p_id==1): $mensaje2.=' '; else: $mensaje2.=' '; endif; $mensaje2.='
Los organizadores de ANAFAPYT LATIN AMERICAN COATINGS SHOW® se pondrán en contacto con usted para confirmar su reservación.
The ANAFAPYT LATIN AMERICAN COATINGS SHOW® Organisers will contact you to confirm your booking.
'; $mail2->MsgHTML($mensaje2); $mail2->IsHTML(true); $mail2->CharSet = 'UTF-8'; if($mail2->Send()): if($p_id==1): $respuestas[]='Su reservación ha sido enviada exitosamente.'; else: $respuestas[]="Your booking has been successful."; endif; else: if($p_id==1): $respuestas[]='Hubo un problema al enviar el mensaje al cliente. Intente de nuevo.'; else: $respuestas[]="There was a problem sending your message. Please try again."; endif; endif; } catch (phpmailerException $g) { $respuestas[]=$g->errorMessage(); //Pretty error messages from PHPMailer } catch (Exception $g) { $respuestas[]=$g->getMessage(); //Boring error messages from anything else! } else: if($p_id==1): $respuestas[]='Su reservación ha sido enviado exitosamente.'; else: $respuestas[]="Your booking has been successful."; endif; endif; else: if($p_id==1): $respuestas[]='Hubo un problema al enviar el mensaje al cliente. Intente de nuevo.'; else: $respuestas[]="There was a problem sending your message. Please try again."; endif; endif; } catch (phpmailerException $e) { $respuestas[]=$e->errorMessage(); //Pretty error messages from PHPMailer } catch (Exception $e) { $respuestas[]=$e->getMessage(); //Boring error messages from anything else! } endif; endif; ?> | ANAFAPYT LATIN AMERICAN COATINGS SHOW®

0): ?>

"; endforeach; ?>