Hi guys'
I'm having trouble with this code
<?php
$link=sqlite_open('data/3001.sqlite ',0666,$sqliteerror);
$comp=sqlite_query($link,"SELECT * FROM assets WHERE asset='chest'");
while($ent=sqlite_fetch_array($comp)){
$item=$ent['content'];
$asset= "array(".$item.")";
echo $asset;
}
$saved=array('food','knife');
$left=array_diff($asset,$saved);
echo $left;
?>
the echo $asset line displays "array(array(food,knife,scarf,torch,key)"
but I get an error
Warning: array_diff() [function.array-diff]: Argument #1 is not an array in C:\xampp\htdocs\abyss\test.php on line 10
when I run it, something simple, but i can't see it.
Any clues please?