View Full Version : empty email from a flash form
pablo
03-07-2006, 01:23 AM
my problem is this,
I´m using a simple (2 textfields) flash form so my visitors can send me an email to my main address.
I using a simple php mail script to do this, but I get an empty message, only the subject of the message that is set in the php script and nothing in the 'body'.
The crazy thing about this is that only happens when y use an swf file to send the data to the php script, If I use an html form the mail arrives perfectly.
I test the same files on other servers and the flash form works just fine...I don´t understand.
Is there any server restriction about swf files ?
the same happens with asp script...
does anybody knows some about It?
joelnet
03-07-2006, 05:02 AM
there aren't any restrictions on flash files.
it is bizzare that it is working differently on one server than it does on ours. try checking the name of the body field in the flash file and making sure they match the variable name in the php file. also try renaming the variable to something else.
Joel Thoms
DiscountASP.NET
http://www.DiscountASP.NET
pablo
03-07-2006, 05:34 AM
Yes, is realy bizzare, the files are located in the forlder /pabloberar1/formtest
the .fla file is also there if you want to check it out.
Can you test it with any other email account ? so I can be sure that I'm not doing nothing wrong
tanks for the help
tanti grazie
pablo
03-08-2006, 03:04 AM
++ This is the php code:
<?
$MailTo = 'info@pabloberardo.com';
// subject
$MailSubject = ' Message from my site';
//'from'
$MailHeader = 'From: $email';
// body ::::::::::::::::::::
$MailBody = 'nombre: $name\r\n';
$MailBody .= 'Family Name: $faname\r\n';
$MailBody .= 'City: $city\r\n';
$MailBody .= 'Country: $country\r\n';
$MailBody .= 'E-mail: $email\r\n';
$MailBody .= 'I know Mussa Phelps by a: $how\r\n';
$MailBody .= 'Recieve information?: $queresinfo\r\n';
$MailBody .= 'Message: $message\r\n';
// send >>>>
mail($MailTo, $MailSubject, $MailBody, $MailHeader);
?>
++ This is the ActionScript code from the flash buton:
on (release) {
if ((email.indexOf('@') != -1) && (email.indexOf('.') != -1) &&
(length(email)>5)) {
loadVariablesNum('mailoso.php', 0, 'POST');
name = '';
faname = '';
city = '';
email = '';
country = '';
how = '';
message = '';
_root.ansu._visible=true ;
_root.ansu.answer = 'Tanks '+quien+','+'
your message has been
sent.';
_root.ansu.gotoAndPlay(2) ;
} else {
email = ' Ø Invalid e-mail address.';
}
}
I tested with other 4 webhosting companies running Linux and works perfect, but
where the email that I recieve from the form is 'empty', only the subject is ok.
Is like the flash it could pass the variable to the php file I don't know why
thanks for the aid
bruce
03-08-2006, 12:43 PM
we can't get access to your site.
Can you post the code?
Bruce
DiscountASP.NET
www.DiscountASP.NET (http://www.DiscountASP.NET)
vBulletin® ©Jelsoft Enterprises Ltd.