Hi there, I am trying to load this php into flash.
<?php
echo "fred";
if(! $connect = mysql_connect("localhost", "root", "") ) die("Connection to DB failed");
mysql_select_db("clipboard", $connect);
$result = mysql_query("SELECT * FROM clip where 1");
echo count($result);
while($row=mysql_fetch_array($result)){
echo "id$cant=$row[id]&movie$cant=$row[movie]&description$cant=$row[description]&type$cant=$row[type]&";
$cant++;
}
echo "cant=$cant";
?>
and am using this .AS. as the flash loading part
myData = new LoadVars()
myData.ref = this
myData.load("clips.php")
myData.onLoad = function(){
if(succes){
for(var i=0; i<this.cant; i++){
this.ref["id"+i].text = this["id"+i]
this.ref["movie"+i].text = this["movie"+i]
this.ref["description"+i].text = this["description"+i]
this.ref["type"+i].text = this["type"+i]
}
} else trace("Error loading data")
}
stop()
Keep getting an error (on the trace)… not sure what I am doing wrong
Anyone help much appreciated?..
SC/