I am a medical student, n00 in php, whitout any experience (still not even solve out what is meant by 'session'), and have only briefed with a short introduction on mysql-php and had read the 'Creating a Membership System' Tutorial http://www.phpfreaks.com/tutorials/40/0.php provided by phpfreaks.com. So, please be patient to read my long but simple questions, I need your help..
I am working on a project to create a database that stores patient's records of medical problems.
I have created 2 tables: (suggested by Gizmola, thanks a lot)
patient
patient_id (Primary Key)
name
username
password
email
address
patient_visit
patient_id (Primary Key)
visit_date (Primary Key)
presenting_complaint
diagnosis
prescribed_treatment
next_appointment
The table patient_visit will be occasionally updated when the patient visit the clinic again.
I have applied the 'Creating a Membership System' Tutorial to my project. So, I have join_form.html and register.php (that will create account for each patient);
activate.php, login_form.html, checkuser.php, and login_success.php (that allow patient to login. Logging-in will allow the patient to view his/her history of visits in the clinic.)
Can you please teach me how to modify or (modify for me) the login_succes.php, so that the history of visits (the recorded information in the table patient_visit) of that particular patient will be directly, or under a link, shown to him/her.
This is the login_success.php provided by the tutorial:
[COLOR=limegreen] <?
session_start();
echo "Welcome ". $_SESSION['name'] ."! You have made it to the members area!<br /><br />";
echo "Your user level is ". $_SESSION['user_level']." which enables you access to the following areas: <br />";
if($_SESSION['user_level'] == 0){
echo "- Forums<br />- Chat Room<br />";
}
if($_SESSION['user_level'] == 1){
echo "- Forums<br />- Chat Room<br />- Moderator Area<br />";
}
echo "<br /><a href=logout.php>Logout</a>";
?>[/COLOR]
Thank you very much