<?php
include "connect_db.php";
$query = "SELECT username,password FROM tbuser";
$result = mysql_query($query, $link) or die('Errorquery: '.$query);
$rows = array();
while ($r = mysql_fetch_assoc($result)) {
$rows[] = $r;
}
$data = "{user:".json_encode($rows)."}";
echo $data;
?>
Tidak ada komentar:
Posting Komentar