PDA

View Full Version : Php/as



luiner
November 5th, 2007, 07:01 AM
I have problem with php -> actionscript comunication

in PHP i have:

echo "&fil=Home&";

flash receive:

Home

and this is ok, but i need variable
in PHP i have:

$ttx="Home";
echo "&fil=$ttx&";

flash receive:

$ttx

I tried plenty of combinations like
echo "&fil=\$ttx&"; receiving \$ttx
echo "&fil=".$ttx."&"; ".$ttx."
echo "&fil=\".$ttx."&"; \".$ttx."

In one word, i need send variable from PHP to variable in AS

some more data:
in flash i'm usig
loadVariables("vars.php", "_root", "POST");
and PHP 5.2.4

Thanx alot for any answer.

simplistik
November 5th, 2007, 08:22 AM
echo "&fil=".$ttx."&";

or you could do


$str = "&fil=".$ttx."&";
echo $str;

not really sure why the first method wouldn't work though