$query = mysql_query("SELECT * FROM fruit WHERE color='red' ");
while ($row = mysql_fetch_array($query)) {
echo $row['name']."|" ;// this echo apple|strawberry|cherry
}
How to make a php variable equal to the result of mysql_fetch_array? I need to make a equal like: $newname="apple|strawberry|cherry", so that I can use the new variable $newname for another process. Thanks.