Buenos Dias... ahora lo hice con el ejemplo del webmaster pero ocurre lo mismo... dice enviado pero no llega nada a mi correo... que podria ocurrir... gracias
este es el codigo del primer frame:
stop();
txt_nom.text = "";
txt_ape.text = "";
txt_emp.text = "";
txt_car.text = "";
txt_mail.text = "";
txt_tel.text = "";
txt_dir.text = "";
txt_com.text = "";
txt_nom.restrict = "A-Z a-z";
txt_ape.restrict = "A-Z a-z";
txt_tel.restrict = "0-9";
Selection.setFocus(txt_nom);
txt_nom.tabIndex = 1;
txt_ape.tabIndex = 2;
txt_emp.tabIndex = 3;
txt_car.tabIndex = 4;
txt_mail.tabIndex = 5;
txt_tel.tabIndex = 6;
txt_dir.tabIndex = 7;
txt_com.tabIndex = 8;
function enviarMail() {
envio_lv.nombre = txt_nom.text;
envio_lv.apellido = txt_ape.text;
envio_lv.empresa = txt_emp.text;
envio_lv.cargo = txt_car.text;
envio_lv.mail = txt_mail.text;
envio_lv.telefono = txt_tel.text;
envio_lv.direccion = txt_dir.text;
envio_lv.comentario = txt_com.text;
envio_lv.sendAndLoad("http://www.miweb.com.ec/formulario/formulario.php", recibir_lv, "POST");
}
var envio_lv:LoadVars = new LoadVars();
var recibir_lv:LoadVars = new LoadVars();
recibir_lv.onLoad = function(exito) {
if (exito) {
mensaje_txt.text = this.mensaje;
trace(recibir_lv);
//_root.exi = this.mensaje;
//_root.attachMovie("exitoso", "exitoso", 100000, {_x: 450, _y: 250});
} else {
mensaje_txt.text = "Error al enviar...";
//_root.avi = "Error al enviar";
//_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}
};
este codigo es del boton:
on (release) {
if(!txt_nom.text.length || !txt_ape.text.length || !txt_mail.text.length || !txt_tel.text.length || !txt_com.text.length){
_root.avi = "Llene todos los campos marcados como obligatorios (*)";
_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}else if (txt_nom.text.length < 3) {
_root.avi = "Error en el campo (Nombre), Por favor verifiquelo";
_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}else if (txt_ape.text.length < 3) {
_root.avi = "Error en el campo (Apellido), Por favor verifiquelo";
_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}else if (txt_tel.text.length < 5) {
_root.avi = "Error en el campo (Teléfono), Por favor verifiquelo";
_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}else if (txt_com.text == "") {
_root.avi = "Error en el campo (Comentario), Por favor verifiquelo";
_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}else if (txt_mail.text.length < 10 || txt_mail.text.indexOf("@") == -1 || txt_mail.text.indexOf(".") == -1) {
_root.avi = "Error en el campo (E-mail), Por favor verifiquelo";
_root.attachMovie("mensaje", "mensaje", 100000, {_x: 450, _y: 250});
}else{
//_root.exi = "Enviando datos, Por favor espere...";
//_root.attachMovie("exitoso", "exitoso", 100000, {_x: 450, _y: 250});
mensaje_txt.text = "Enviando datos...";
enviarMail();
}
}
y este es el php:
<?php
$sendTo = "
[email protected]";
$subject = "(|-_-|)";
$contenido .=$contenido . $_POST["mail"]
mail($sendTo, $subject, $contenido);
echo "mensaje = !Mensaje enviado¡";
?>