duda
03-27-2004, 04:08 PM
hello
i have a little big problem with loading variables into flash.
i have tried with loadVars class and with MovieClip.loadVariables
but it doesn't work!
here is the actionscript:
locData= new LoadVars();
locData.load("plan.php");
nr=locData.nr;
but nr remaind undefined
the php works because i've tested it.
the code id:
<?php
mysql_connect("localhost","user","pass");
mysql_select_db("db");
$qr = @mysql_query("SELECT * FROM table");
$nrows = mysql_num_rows($qr);
$rString = "nr=".$nrows;
for ($i=0; $i < $nrows; $i++) {
$row = mysql_fetch_array($qr);
$rString .= "&name".$i."=".$row['name'];
$rString .= "&img".$i."=".$row['img'];
$rString .= "&text".$i."=".$row['text'];
}
echo $rString;
?>
so what happens? :confused:
10x a lot!
:D
i have a little big problem with loading variables into flash.
i have tried with loadVars class and with MovieClip.loadVariables
but it doesn't work!
here is the actionscript:
locData= new LoadVars();
locData.load("plan.php");
nr=locData.nr;
but nr remaind undefined
the php works because i've tested it.
the code id:
<?php
mysql_connect("localhost","user","pass");
mysql_select_db("db");
$qr = @mysql_query("SELECT * FROM table");
$nrows = mysql_num_rows($qr);
$rString = "nr=".$nrows;
for ($i=0; $i < $nrows; $i++) {
$row = mysql_fetch_array($qr);
$rString .= "&name".$i."=".$row['name'];
$rString .= "&img".$i."=".$row['img'];
$rString .= "&text".$i."=".$row['text'];
}
echo $rString;
?>
so what happens? :confused:
10x a lot!
:D