$artistname = versiering ($_POST [„artistname“]);
$get_artistID_sql = mysql_query („SELECTEER artistID UIT kunstenaars WAAR artistname = „“ .mysql_real_escape_string ($artistname). „“ „);
$artistID = mysql_fetch_row ($get_artistID_sql);
$get_albums_sql = mysql_query („SELECTEER albumname UIT albums WAAR artistID = „“. $artistID [0]. „“ „);
$albums = mysql_fetch_row ($get_albums_sql);
$j = serie ();
terwijl ($row = mysql_fetch_array ($get_albums_sql))
{
$j [] = serie (value=>$row [0], name=>$row [0]);
}
echo json_encode (serie („resultaten " =>$j));
|