1 Reply Latest reply on Aug 27, 2006 12:13 PM by izm067

    Flash 8 send sendAndLoad not sending what I think to the perl script

      I am trying to collect data from a form in Flash 8 and send it to an email address. I followed the tutorials on lynda.com for Building a form. I have used the following actionscript.

      var gatherForm:LoadVars = new LoadVars();
      function sendForm() {
      gatherForm.MAIL_TO = "me@mchsi.com";
      gatherForm.visitorfname = fmcontact.fmuserfname.text;
      gatherForm.visitorlname = fmcontact.fmuserlname.text;
      gatherForm.visitoremail1 = fmcontact.fmemailaddr1.text;
      gatherForm.visitoremail2 = fmcontact.fmemailaddr2.text;
      gatherForm.visitortelarea = fmcontact.fmtelarea.text;
      gatherForm.visitortelnum = fmcontact.fmtelnum.text;
      gatherForm.visitorcomments = fmcontact.fmcomments.text;

      gatherForm.send(" http://www.mywebsite.com/cgi-bin/formscr.cgi", "_blank", "POST");

      The cgi script I am trying is one I have used successfully with html. It does not recognize any of the flash variables I am trying to send to it. If I hard code my email in the cgi script, I get an email, but no variables appear to have been passed to it from my flash 8 swf. I tried using the FormMail.pl script v 1.92 from Matt Wright and set gatherForm.recipient = "my email addr" and I appear to have the same error indicating the script did not receive an email address.

      I would like to be able to send the form without the popup caused by the "_blank" parameter, but I am trying to start with something simple before I add more complexity and I can't seem to even get the simple taskt to work.

      If someone could help I would appreciate it. I have tried to read the other cases on the forum, but they all seem to have a twist to them that doesn't seem to help.