5 Replies Latest reply on Apr 24, 2007 1:42 PM by kglad

    returning php vars to flash AS

    ledatica
      Hi,

      I am not able to get a variable value from PHP back into flash after sendAndLoad. I can only get the actual value returned by php. here is the detail.

      Initially from flash

      dataOut.sendAndLoad("phptest.php", dataIn, "POST");

      and the return from phptest.php

      dataIn.onLoad = function() {
      msg.text = ' returned from php is '+this.value1 + this.value2 ;
      }

      the code in phptest.php

      <?php
      $a = "&value1=foo&";
      $b = "&value2=";
      $c = "bar&";

      echo $a.$b.$c;

      ?>
      in response
      the msg.text reads like this

      returned from php is foo";

      It only returns the actual value of value1 and not the passed value of value2, but one doublequote.

      and this is what is displayed in the browser from the phptest.php .

      &value1=foo&&value2=bar&


      any sugggestions. ?

      Thanks for any help