keep in mind this is a simple insert and select example, may be parse errors, didn't check just threw this together quick
use this for insert page, obviously mine i wrote quick for you is generic and you may have to use $_POST['var'] for your variables if register_globals is off, but you should get the hint
<html>
<head>
<title>Untitled</title>
</head>
<body>
<?
if(isset($submit))
{
$conn = mysql_connect("localhost", "xxxxx", "xxxxxx") or die ("Could not connect to database!");
$db = mysql_select_db("databasename") or die ("Could not select database");
$query = "insert into tablename (field1, field2) values ($form1, $form2);";
$result = mysql_query($query);
?>
Information has been submitted<br>
<?
}
else
{
?>
Enter information and hit submit
<form action="insert.php" method="post">
<input type="text" name="form1">
<input type="text" name="form2">
<input type="submit" name="submit">
</form>
<?
}
?>
</body>
</html>
then use this to retrieve the results from the table and keep in mind what i said about $_POST['var'] for accessing variables
<html>
<head>
<title>Untitled</title>
</head>
<body>
<?
$conn = mysql_connect("localhost", "xxxxx", "xxxxxx") or die ("Could not connect to database!");
$db = mysql_select_db("databasename") or die ("Could not select database");
$query = "select * from tablename;";
$result = mysql_query($query);
while ($row = mysql_fetch_array($result))
{
echo $row['field1'] . "<br>";
echo $row['field2'] . "<br><br>";
}
?>
</body>
</html>