ryanT
-
Posts
4 -
Joined
-
Last visited
Never
Posts posted by ryanT
-
-
no difference, same error
Method Not Allowed
The requested method POST is not allowed for the URL /parent/submit.php. -
Same Result:
Method Not Allowed
The requested method POST is not allowed for the URL /parent/submit.php. -
Im getting this error while simply trying to post to a DataBase...
The requested method POST is not allowed for the URL /parent/insert.php.
I can't figure out why.. please help
[code]<html>
<head>
<title>submit form</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php
if(isset($_POST['add']))
{
$username="XXXXXr";
$password="XXXXX";
$database="XXXXX";
$pfirst=$_POST['parentfirst'];
$plast=$_POST['parentlast'];
$pphone=$_POST['parentphone'];
$pemail=$_POST['parentemail'];
$kfirst=$_POST['kidfirst'];
$kemail=$_POST['kidemail'];
$wish=$_POST['kidwishlist'];
$pi=$_POST['parentinitals'];
mysql_connect("XXX.XXXXX.XXX",$username,$password);
@mysql_select_db($database) or die( "Unable to select database");
$query = "INSERT INTO contacts VALUES ('','$pfirst','$plast','$pphone','$pemail','$kfirst','$kemail','$wish','$pi')";
mysql_query($query);
mysql_close();
echo "added";
}
else
echo "not added";
{
?>
<form method="post" action="submit.php">
Parent First Name: <input type="text" name="parentfirst"><br>
Parent Last Name: <input type="text" name="parentlast"><br>
Parent Phone: <input type="text" name="parentlast"><br>
Parent Email: <input type="text" name="parentemail"><br>
Kid First Name: <input type="text" name="kidfirst"><br>
Kid E-mail: <input type="text" name="kidemail"><br>
Kid Wish List: <input type="text" name="kidwishlist"><br>
Parent Initals: <input type="text" name="parentinitals"><br>
<input name="add" type="submit" id="add" value="Submit">
</form>
</body>
</html>[/code]
The requested method POST is not allowed
in PHP Coding Help
Posted
heres the page
http://www.scparent.com/santa/submit.php