I want if is possible to display the username in new row instead of one next to other (e.g. adminuser1user2
admin
user1
user2 )
$con = mysql_connect('localhost','root','');
mysql_select_db('chatbox',$con);
$sql = "SELECT `username`
FROM `users`
ORDER BY `username` ASC";
$result = mysql_query($sql);
if($result === FALSE) {
die(mysql_error());
}
while($row = mysql_fetch_array($result))
{
echo $row['username']; //over here
}
?>
Aucun commentaire:
Enregistrer un commentaire