0
<html>
<head>
<title>Records</title>
</head>

<body>

<?php

$fname=$_POST['fname'];
$age=$_POST['age'];
$birthday=$_POST['birthday'];


$con = mysql_connect('localhost', 'root' , '');
	
if (! $con)
	{
die(mysql_error());
mysql_select_db("database" , $con) or die("Select Error: ".mysql_error());
	}	
$result=mysql_query("INSERT INTO Record (Name, Age, Birthday) VALUES (
'$fname',
'$age', 
'$birthday')") or die("Insert Error: ".mysql_error());
mysql_close($link);
print "Record added";
?>
<form method="POST" action="birthdays_insert_form.php">
<input type="submit" value="Insert Another Record">
</form>
<br>

<form method="POST" action="birthdays_dbase_interface.php">
<input type="submit" value="Dbase Interface">
</form>



</body>
</html>

Edited by abelingaw: n/a

2
Contributors
2
Replies
3
Views
6 Years
Discussion Span
Last Post by abelingaw
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.