Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Apr 2004
    Posts
    25
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Script Proccessing of a flash form!

    Hi guys

    My flash form has 3 input text fields and 1 dynamic text field. See www.razmataz-designs.co.uk click on flash site. I followed a tutorial and everything seemed ok until i posted it on the net. I keep getting a blank email and for every one press on the send button im getting tens of blank emails. Also the script is not sending the confirmation message back to the dynamic text field in the form. Ive attached a stand alone form and the script im using can anyone help me identify the problem?
    link to my fla file
    http://www.razmataz-designs.co.uk/form.fla

    The script i used

    <?
    $ToEmail = "info@razmataz-designs.co.uk";

    $ToName = "Barry";
    $ToSubject = "Message From Razmataz Designs Flashsite";

    $EmailBody = "Sent By: $FirstName\nSenders Email: $Email\n\nMessage Sent:\n$ToComments\n";

    $Message = $EmailBody;

    mail($ToName." <".$ToEmail.">",$ToSubject, $Message, "From: ".$FirstName." <".$Email.">");


    Print "_root.Mail.EmailStatus=Complete - Your mail has been sent";
    ?>


    Cheers
    Last edited by Bazrazmataz; 05-21-2004 at 07:48 PM.

  • #2
    New Coder
    Join Date
    May 2003
    Posts
    71
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Unfortunately, I cannot open the FLA on this PC as I do not have flash installed. However, I may know the answer, but it depends if you are sending the results by GET or POST.

    If by GET change your PHP code to this:
    PHP Code:
    <?php
    $ToEmail 
    "info@razmataz-designs.co.uk";

    $ToName "Barry";
    $ToSubject "Message From Razmataz Designs Flashsite";

    $EmailBody "Sent By: $FirstName\nSenders Email: $Email\n\nMessage Sent:\n{$_GET['ToComments']}\n";

    $Message "{$_GET['EmailBody']}";

    mail($ToName." <".$ToEmail.">",$ToSubject$Message"From: "{$_GET['FirstName']}" <"{$_GET['Email']}">");


    Print 
    "_root.Mail.EmailStatus=Complete - Your mail has been sent";
    ?>

    If by POSTchange your PHP code to this:
    PHP Code:
    <?php
    $ToEmail 
    "info@razmataz-designs.co.uk";

    $ToName "Barry";
    $ToSubject "Message From Razmataz Designs Flashsite";

    $EmailBody "Sent By: $FirstName\nSenders Email: $Email\n\nMessage Sent:\n{$_POST['ToComments']}\n";

    $Message "{$_POST['EmailBody']}";

    mail($ToName." <".$ToEmail.">",$ToSubject$Message"From: "{$_POST['FirstName']}" <"{$_POST['Email']}">");


    Print 
    "_root.Mail.EmailStatus=Complete - Your mail has been sent";
    ?>

    My guess is your hosting server has register globals turned off. Now, do not quote me on that, as it is only a guess, but it may be the reason.
    cpCommerce - Finally a template based open-source e-commerce solution

  • #3
    New Coder
    Join Date
    Apr 2004
    Posts
    25
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Pardon my ignorance but what is the difference between get or post ?

  • #4
    New Coder
    Join Date
    Apr 2004
    Posts
    25
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I tried both scripts and both did not work. I revice no email at all now and still get no confimation to the movie ! im getting really frustriaghted niow!

  • #5
    New Coder
    Join Date
    Apr 2004
    Posts
    25
    Thanks
    0
    Thanked 0 Times in 0 Posts
    This is what ive tried next without any success!!

    <?php
    $sendTo = "info@razmataz-designs.co.uk";
    $subject = "Message From Razmataz Designs Flashsite";

    $headers="From:". $_POST["FirstName"];
    $headers .= "<" . $_POST["email"] .">\r\n";
    $message = $_POST["ToComments"];

    mail($sendTo, $subject, $message, $headers);
    Print "_root.Mail.EmailStatus=Complete - Your mail has been sent";

    ?>

    Well i just tested this one and got different results again. Again confirmation was not sent back to the movie but a separate window popped up saying :_root.Mail.EmailStatus=Complete - Your mail has been sent

    Now i recived an email this time but again it was blank and my email account had this error message :

    Warning: Invalid argument supplied for foreach() in /var/www/squirrelmail/src/read_body.php on line 620

    So now im totally lost!!

    Just altered script to:

    <?php
    $sendTo = "info@razmataz-designs.co.uk";
    $subject = "Message From Razmataz Designs Flashsite";

    $headers= $_POST["FirstName"];
    $headers .= $_POST["email"];
    $message = $_POST["ToComments"];

    mail($sendTo, $subject, $message, $headers);
    Print "_root.Mail.EmailStatus=Complete - Your mail has been sent";

    ?>

    No error message in my email account now but still getting a blank message. And dont understand why the poppup message is appearing in a window rather than in my dynamic text field!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •