A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: LoadVars.send() not working

Hybrid View

  1. #1
    Member
    Join Date
    Dec 2002
    Location
    Seattle
    Posts
    47

    LoadVars.send() not working

    i have been able to get this to work using the geturl() but not with the loadvars object. trace prints what i would expect to see.

    here is the code in my flash button.

    code:

    on (release) {
    submit = new LoadVars();
    submit.returnAddress = txt1.text;
    submit.messageBody = txt2.text;
    if (submit.returnAddress.length && submit.returnAddress.indexOf("@") != -1 && submit.returnAddress.indexOf(".") != -1 && submit.messageBody.length) {
    sumbit.send("http://www.webaddresshere.com/submit.php","_blank","POST");
    trace(submit);
    }
    }



    and my php

    PHP Code:
    <?php
    $toAddress
    ="[email protected]";
    $subject="Message From Website";
    $returnAddress=$HTTP_POST_VARS[returnAddress];
    $message=$HTTP_POST_VARS[messageBody];
    mail($toAddress$subject$message"From:$returnAddress\r\n");
    ?>
    Last edited by jbum; 10-08-2004 at 03:09 PM.

  2. #2
    Senior Member jbum's Avatar
    Join Date
    Feb 2004
    Location
    Los Angeles
    Posts
    2,920
    Looks like you mispelled 'submit' at least once - check out the next to last line.

  3. #3
    Member
    Join Date
    Dec 2002
    Location
    Seattle
    Posts
    47

    still another problem.

    thank you for catching that.

    I can't get this to work using a post method, it seems to only want to use get. is there anything else i need to do to get it to use post?

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center