hello,
i have a basic code, and i want to fetch a data from mysql using PHP, and display in my html page; i just want to have a basic idea so i can add more details later on, like data of birth, nationality, profession etc.
im planning to make a simple out put that looks like a filled up application form.
for example:
(in a filled up registration form output, normally there should be an underline for the output)
Company: ___
Name: <td style="text-decoration:underline;">adam</td>
date of birth: _____
profession: engineer
nationality:____
my database:
===========
id | name | address |
---------------------
1 | adam | sydney |
---------------------
2 | john | turkey |
<?php
mysql_connect("localhost","root","password");
mysql_select_db("employees_test");
$order = "SELECT * FROM data_employees";
$result = mysql_query($order);
while($data = mysql_fetch_row($result)){
echo $data[0];
}
?>
My Question:
- how can i add ID in my database?
- how to fetch data individually? is it only an object?
thanks