Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

problem Method Not Allowed

Status
Not open for further replies.

crashuk

Technical User
Sep 12, 2005
77
GB
The requested method POST is not allowed for the URL
/customerwebportal/processfeedback.php
iam using apache, after i enter my details and press submit i get the above statement



<html>
<head>
<title>help- Customer Feedback</title>
</head>
<body>

<h1>Customer Feedback</h1>

<p>Please tell us what you think.</p>

<form method=post action="processfeedback.php">
Your name: <br />
<input type=text name="name" size=40><br />
Your email address: <br />
<input type=text name="email" size=40><br />
Your feedback:<br />
<textarea name="feedback" rows=5 cols=30>
</textarea><br />
<input type=submit value="Send feedback">
</form>
</body>

php file

<?php
//create short variable names
$name=$_POST['name'];
$email=$_POST['email'];
$feedback=$_POST['feedback'];

$toaddress = 'feedback@example.com';
$subject = 'Feedback from web site';
$mailcontent = 'Customer name: '.$name."\n"
.'Customer email: '.$email."\n"
."Customer comments: \n".$feedback."\n";
$fromaddress = 'From: webserver@example.com';

mail($toaddress, $subject, $mailcontent, $fromaddress);
?>
<html>
<head>
<title>- Feedback Submitted</title>
</head>
<body>
<h1>Feedback submitted</h1>
<p>Your feedback has been sent.</p>


</body>
</html>
 
Doing some googling on this, there appear to be many others with the same error message. One suggestion to resolve this was to remove the index.html file (if it is present) in the same directory.

Cheers,
Jeff

[tt]Jeff's Page @ Code Couch
[/tt]

What is Javascript? FAQ216-6094
 
ok now i get this, i looked at google and changed a few things now the php script dosent work

customerwebportal/feedback.html when i click submit

its goes to the following page

customerwebportal/processfeedback.php

and says
The page cannot be found
The page you are looking for might have been removed, had its name changed, or is temporarily unavailable.


 
you mean this

customerwebportal/processfeedback.php

<form method=post action="processfeedback.php">


<form method=post action="customerwebportal/processfeedback.php">
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top