Avg. Rating 3.1

Problem

I have a form (simple name, email, message) that needs to be submitted in my Flex App. It emails my email via a PHP file. Well when submited I get the Error 2070 Sandbox error, cannot access stage. I have the crossdomain.xml file at the www rootfolder and yet it still yields this error.

Solution

I have tried everything that I know. I really need help here.

Detailed explanation

here is my mxml file:

 

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
  <mx:HTTPService id="srv" url="http://www.rudysportfolio.com/flexTest/mail.php" method="POST">
    <mx:request>
  <user>{user.text}</user> 
      <email>{email.text}</email>
      <message>{message.text}</message>
    </mx:request>
  </mx:HTTPService>
  <mx:Form>
    <mx:FormItem label="Name">
      <mx:TextInput id="user"/>
    </mx:FormItem>
    <mx:FormItem label="Email">
      <mx:TextInput id="email"/>
    </mx:FormItem>
    <mx:FormItem label="Message">
     <mx:TextArea width="211" height="117" id="message" />
    </mx:FormItem>     
    <mx:FormItem>
      <mx:Button label="Submit" click="srv.send()"/>
    </mx:FormItem>
  </mx:Form>
</mx:Application>

 

and my php file:

<?php

$address = "rugu87@hotmail.com";

$subject = "subject line tester";

$body = $_POST['user'] . " had this to say:\n" . stripslashes($_POST['message']);

$extra_header_str = "From:" . $_POST['email'];

$mailsend = mail($address,$subject,$body,$extra_header_str);

echo $mailsend;

?>

Report abuse

Related recipes