Jump to content

enviar vars flash para php?


Recommended Posts


alguem pode eplicar me como passo variaveis flash para o php?

eu tenho isto FLASH (as2):

var envioVariaveis:LoadVars = new LoadVars();



no PHP:

echo "cor escolhida foi: ".$_REQUEST['cor'].'<br>';

....não passa valor nenhum para lá


Link to comment
Share on other sites

  • 3 weeks later...

NO FLASH tens algo assim:

System.useCodepage = true;
var arquivo:XML = new XML();

arquivo.ignoreWhite = true;
arquivo.onLoad = function() {

new.text = this.childNodes[0].childNodes[0].attributes.new;


No file php, faz o seguinte:


$link = mysql_connect("localhost","user","pw");

$query = 'SELECT newROW FROM newsbd LIMIT 1';
$results = mysql_query($query);

echo "<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>";
echo "<post>\n";

while($line = mysql_fetch_assoc($results)) {
echo "<new new='$line[new]'/>\n";

echo "</post>\n";


Como ja deves ter reparado aqui no que escrevi usa xml pra passar vars.

Se alguém puder por outras formas força, assim ficas com mais exemplos 😛

Espero que ajude ;D

<?PHP echo "Bo0m"; ?>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.