help please form in flash not sending to php

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Derek
    New Member
    • Mar 2007
    • 12

    help please form in flash not sending to php

    Hi all any one please help, i have a buttin in flash 8 which gets a form contact.php but when it is pressed the emial ruturns empty as follows
    1 the flash button
    2 the form
    3 the email outcome (empty)
    the form
    on (release) {
    _parent.getURL( "contact.php"," _blank",
    "GET");
    _parent.name="" ;
    _parent.phone=" ";
    _parent.email=" ";
    _parent.message ="";
    }
    the contact.php (this has been cleared in the php department) it should work
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>Contac t</title>
    </head>
    <?php



    $to = "derek@conc rete-crusher.co.uk";
    $subject = "Contact letter";
    $message = "Hello! \n";
    $message .= "Name: " . $_GET['name'] . "\n";
    $message .= "Phone: " . $_GET['phone'] . "\n";
    $message .= "E-mail: " . $_GET['email'] . "\n";
    $message .= $_GET['message'] . "\n";
    $headers = "From: " . $_GET['email'] . "\r\n" .
    "Reply-To: " . $_GET['email'] . "\r\n" .
    "X-Mailer: PHP/" . phpversion();

    mail($to, $subject, $message, $headers);

    ?>
    <html>
    <body bgcolor="#282E2 C">
    <div align="center" style="margin-top:60px;color: #FFFFFF;font-size:11px;font-family:Tahoma;f ont-weight:bold">
    Your message was sent. Thank you.
    </div>
    </body>
    </html>
    <script>resizeT o(300, 300)</script>r

    <body>
    </body>
    </html>

    the emial outcome
    Hello!
    Name:
    Phone:
    E-mail:

    no content any one help please

    Best wishes Derek
  • iam_clint
    Recognized Expert Top Contributor
    • Jul 2006
    • 1207

    #2
    on (release) {
    _parent.getURL( "contact.php"," _blank",
    "GET");
    _parent.name="" ;
    _parent.phone=" ";
    _parent.email=" ";
    _parent.message ="";
    }


    I would need to see your flash page but

    _parent.name="" ; will always = nothing you need to set it by using whatever was typed in the text field. aka _parent.name = _parent.name.te xt;

    Comment

    • Derek
      New Member
      • Mar 2007
      • 12

      #3
      Hi thanx for getting back to me, i really have spent weeks on this form, what make it worse was i moved to a vurtual server at the same time so obviously my thoughts kept coming back to the problem being with the server.
      Do you mean lke this

      on (release) {
      _parent.getURL( "contact.php"," _blank",
      "GET");
      _parent.name="n ame";
      _parent.phone=" phone";
      _parent.email=" email";
      _parent.message ="message";
      }

      the form is at www.concrete-crusher.co.uk
      and is the contact form

      once again thank you for your time
      Best wishes Drek

      Comment

      • iam_clint
        Recognized Expert Top Contributor
        • Jul 2006
        • 1207

        #4
        on (release) {
        _parent.getURL( "contact.php"," _blank",
        "GET");
        _parent.name="n ame";
        _parent.phone=" phone";
        _parent.email=" email";
        _parent.message ="message";
        }

        See when you do it like this


        All your email is going to ever show is
        name: name
        phone: phone
        email: email
        message: message


        You need to be pulling that information from your flash form which Only you would know the names of the form elements to pull the data from.

        Comment

        • Derek
          New Member
          • Mar 2007
          • 12

          #5
          The problem i get when i do it like that is just the headings in the contact.php
          and noughing from Flash. Do you mean the var in flash = the form
          e.g. text input box = var:name?? i would be happy for you to have a copy of the .fla if i could send it to an email address
          best wishes Derek

          Comment

          • iam_clint
            Recognized Expert Top Contributor
            • Jul 2006
            • 1207

            #6
            you may send it to me at iam_clint@hotma il.com

            You need to be pulling the data into your form variables from the text boxes within the flash object

            Comment

            • Derek
              New Member
              • Mar 2007
              • 12

              #7
              Hi Iam its on its way, I hope you can receive a 7MB file
              Derek

              Comment

              Working...