Codice PHP:
function sponsor() {
$query = "SELECT sponsor1, sponsor2 FROM utenti WHERE id = '$id'";
$result = mysql_query($query);
$row = mysql_fetch_row($result);
if(!empty($row['sponsor1'])){
return "[img]si.png[/img]";
}else{
return "[img]no.png[/img]";
}
if(!empty($row['sponsor2'])){
return "[img]si.png[/img]";
}else{
return "[img]no.png[/img]";
}
}