View Full Version : need help with codes for logging into database

08-23-2007, 11:12 AM
hey i have to create a database for a hotel for my University Re-sits, part of the work is so the newly registered customers can log in the to customer area to search/make a booking. However im a bit confused on how to do this - we've been given default codes to copy and paste but im stuck from then on. Ive included the login.html and customerpage.php codes.


<TITLE> Track Add </TITLE>
<BODY BGCOLOR=lemonchiffon>

<form NAME="GetCode" ACTION="customerpage2.php" METHOD=post>

<div align="center"><b><font size="4"> Customer log-in page</font><b><font size="3">&nbsp;</font></b></b></div>
<div align="center">
<p> Username
<INPUT Name ="ID_Search" maxlength = 30 > </p>
<div align= "centre">
<p> Password
<INPUT Name ="Pwd_Search" type="password" maxlength = 30 ></p>
<div align= "centre"> </div>
<input type="submit" value="Enter" name="SUBMIT" >


Customerpage.php Coding

<TITLE>Check Customer ID</TITLE>
<body BGCOLOR=lemonchiffon>

<font size="4">Customer Page<hr>
<a href="http://puma.marjon.ac.uk/~your_user_name/path&filename" target="_self">Click here</a> to return to the home page<p></p>


$User_ID = $_POST['ID_Search'];


<p>Make a booking... </p>
<p>Search for a booking...</p>

08-23-2007, 11:40 AM
what type of database are you using? mysql?

08-23-2007, 11:45 AM
yeh PHPMyAdmin and MySQL

08-23-2007, 11:53 AM
So have you set up a database and a table and don't know how to store data into the table or you haven't set up the database yet?

08-23-2007, 12:22 PM
is your "customepage.html" like a personal profile only for that person logged in to see?

because if so, i'm actually in the same situation right now and can't find an answer.