<?PHP
// Create a connection
$Con = mysql_connect("localhost", "root", "");
// Select Database
mysql_select_db("Database", $Con);
mysql_query("SET CHAR SET UTF8", $Con);
$SQLQuery = "SELECT * FROM `members`";
$Result = mysql_query($SQLQuery, $Con);
$NumRows = mysql_num_rows($Result);
// Create a table
print "<Table border=1><Tr><td>شماره عضویت</td><td>نام</td><td>نام خانوادگی</td></Tr><Tr>";
for ($i=0;$i<$NumRows;$i++){
$Row = mysql_fetch_array($Result);
print "<td>".$Row["ID"]."</td><td>".$Row["Firstname"]."</td><td>".$Row["Lastname"]."</td></tr><tr>";
}
Print "</table>";
// Close Connection
mysql_close($Con);
?>