Flash Form - Processing with PHP problem

Ask a Question related to Macromedia Flash Data Integration, Design and Development.

  1. #1

    Default Flash Form - Processing with PHP problem

    I'm processing my Flash Form by sending the form to a PHP script. The script
    then emails the form's variables to me, but when I get my form through the
    email, I get these obtrusive variables with information I don't want and makes
    the information hard to find. Here's a couple of examples of the variables
    I've recieved.

    Name: <TEXTFORMAT LEADING=\"2\"><P ALIGN=\"LEFT\"><FONT FACE=\"Times\"
    SIZE=\"14\" COLOR=\"#333333\" LETTERSPACING=\"0\" KERNING=\"0\">Monkey
    Test</FONT></P></TEXTFORMAT>
    Email: <TEXTFORMAT LEADING=\"2\"><P ALIGN=\"LEFT\"><FONT FACE=\"Times\"
    SIZE=\"14\" COLOR=\"#333333\" LETTERSPACING=\"0\"
    KERNING=\"0\">monkey@monkey</FONT></P></TEXTFORMAT>

    I've included my PHP script in case that's the problem, but the script works
    perfectly fine in a HTML form. Any help or suggestions would be greatly
    appreciated, thanks.

    <?php
    $sendTo = "nada@nada.com";
    $subject = "Nada Form";

    $name=$_POST['nameField'];
    $email=$_POST['emailField'];
    $phone=$_POST['phoneField'];
    $fax=$_POST['faxField'];
    $address=$_POST['addressField'];
    $message=$_POST['messageField'];

    $name=trim($name);
    $email=trim($email);
    $phone=trim($phone);
    $fax=trim($fax);
    $address=stripslashes($address);
    $message=stripslashes($message);

    $fullMessage = "Name: ".$name."\nEmail: ".$email."\nPhone: ".$phone."\nFax:
    ".$fax."\nAddress: ".$address."\nMessage: ".$message;

    $headers .= "Reply-To: " . $_POST["emailField"] . "\r\n";
    $headers .= "Return-path: " . $_POST["emailField"];

    mail($sendTo, $subject, $fullMessage);
    ?>

    jsolo2001 Guest

  2. Similar Questions and Discussions

    1. DW MX - Extension for Form Processing?
      Hello, I'm back on DW MX after a break from it. And in a way, I'm addressing here the crux of why I had to go back to Frontpage for a while. In...
    2. Form Processing Applications
      I have not had much experience with forms processing, but need to build one for a site. I saw a link to Kmita-mail (http://www1.kmita-mail.com/)...
    3. Secure Form processing
      After a user clicks the submit button on an order form, I am unable to get the redirect specified in the form to go to a secure page. This causes...
    4. Form Processing
      Hi, I am designing a basic email form using Dreamweaver and the checks are successful. Does Dreamweaver have any functionality to enable me to...
    5. More form processing
      Hey folks, I need some of your expertiese again. I am creating a survey form and need some help gathering the results of a question that has...
  3. #2

    Default Re: Flash Form - Processing with PHP problem

    Looks like you're posting TextField.htmlText instead of TextField.text


    Raymond Basque Guest

  4. #3

    Default Re: Flash Form - Processing with PHP problem

    I a having the same problem. RB,will you please expound on your response? Thank you
    amagen Guest

  5. #4

    Default Re: Flash Form - Processing with PHP problem

    Hey guys, glad to know that other people have encountered the same problem!
    Raymond I looked up TextField.html in the help section in Flash, it came up but
    I'm not sure how to incorporate this into my action script. Here's the example
    I found, would something along these lines be all the Actionscript I need?

    this.createTextField("my_txt", this.getNextHighestDepth(), 10, 10, 400, 22);
    my_txt.html = true;

    Thanks

    jsolo2001 Guest

  6. #5

    Default Re: Flash Form - Processing with PHP problem

    You need to make sure your form submission sends the plain text value of the
    TextField. You do not want to send TextField.htmlText if the html property
    is set to true.

    Here's a simple example of what happens when you set TextField.html to true
    and get the htmlText value.

    var tf:TextField =
    this.createTextField("my_txt",
    this.getNextHighestDepth(),
    10, 10, 400, 22);

    tf.text = "Hello World!";

    // set html to true
    // the htmlText and text properties
    // return different values
    tf.html = true;
    trace(tf.text);
    trace(tf.htmlText);

    // set html to false
    // both htmlText and text properties
    // return the same value
    tf.html = false;
    trace(tf.text);
    trace(tf.htmlText);


    Raymond Basque Guest

  7. #6

    Default Re: Flash Form - Processing with PHP problem

    Thanks for the example Raymond. I tried your script and have a clear idea of
    how this text stuff works. The only thing is that I'm not sure how to apply
    this to my form. How to send the results from e.g. -

    tf.html = false;

    - through email, if it's a input field. Here's my code for my submit button,
    nothing fancy just gather up the variables and send.

    on (release) {
    if (nameField eq "" || emailField eq "" || messageField eq "") {
    errorBox._x= 120;
    } else {
    loadVariablesNum("process.php", 0, "POST");
    gotoAndStop(2);
    }
    }

    I have a total of 6 input variables - nameField, emailField, messageField,
    phoneField, faxField and addressField. What would I have to do to get the
    "html=false" results to send. Add more code? If you could provide me with
    another example of code for input fields that'd be great. Thanks for your help
    again.




    jsolo2001 Guest

  8. #7

    Default Re: Flash Form - Processing with PHP problem

    OK. I've never used variables attached to TextFields, but a quick test
    indicates default behavior to be that if the TextField is set to "Render as
    HTML" (TextField.html=true), the variable will be populated with the
    htmlText value.

    It would seem that the easiest way to change that behavior is to select each
    TextField and unselect the property in the properties panel.



    Raymond Basque Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139