473,406 Members | 2,220 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Method POST not allowed error when submitting a form.

this is my html /php form but every time i click submit it says
the metod post is not alowed how can i fix this
Expand|Select|Wrap|Line Numbers
  1.  <!-- Form made by cody.m -->
  2. <center>
  3.  <FORM METHOD="POST" ACTION="test.php">
  4.  <font color="red">*</font>First Name: <INPUT TYPE="text" VALUE="Joe king" SIZE="20" onFocus="this.value=''">
  5.  
  6.  <font color="red">*</font>E-Mail: <INPUT TYPE="text" VALUE="removed email address" SIZE="30" onFocus="this.value=''">
  7.  
  8.  </p>
  9.  <center>
  10. <pre>Comments or feedback:</pre><TEXTAREA NAME="comment" ROWS=10 COLS=50></TEXTAREA>
  11.  <BR>
  12.  </center>
  13.  <INPUT TYPE="submit">
  14.  <INPUT TYPE="reset">
  15.  
  16.  </form>
  17.  
  18.  </center>
  19. <!-- END OF "Form made by cody.m" -->
Dec 31 '08 #1
4 2664
What says the method 'post' is not allowed? Is your web browser saying this? Or is PHP saying this? I'm guessing it's your web browser. If so, what browser are you using? Internet Explorer? Firefox? Safari? Have you tried it in a different browser?

Your code is very old fashioned (that's the way web pages were written 5 years ago), but it should work.

Apart from you need:
name="give_me_a_name"
on each of your <input tags. Otherwise you wont be able to use php to get the values that the user enters. (You'll need $_POST['name_you_gave_it'] to get the value.)

Also, I'd recommend getting rid of
onFocus="this.value=''"
That will probably piss people off when they try to use it.
Jan 1 '09 #2
Markus
6,050 Expert 4TB
codyshea2000,

When posting code in the forums, it is required that you wrap the code in [code] tags. You can do this by simply highlighting the code and then hitting the '#' button at the top of our editor (where you write your post). Doing this formats your code and, in return, helps our experts read it and give an answer.

If you have any doubts, you can have a look over our Posting Guidelines to get familiar with the rules.

Thanks,
Moderator.
Jan 1 '09 #3
Atli
5,058 Expert 4TB
codyshea2000,

I have changed the title of this thread to better describe it's contents.
Using phrases like "help me please!" as a thread title is not allowed.
(See Use a good thread title for more info on how to make a good title).

When posting in these forums, you are required to follow the Posting Guidelines.
This is NOT optional, and failure to do so will eventually lead to a ban on your account.

Make sure to you follow them when posting here in the future.

Moderator
Jan 1 '09 #4
Codyshea, you sent me a personal message or something? I can't find it now, but you said you were using Firefox.

I've tried your code and it seems to work. Although there seems to be a stray </p> tag on line 8. It's not effecting anything, but you should take it out.

Are you sure there isn't something somewhere else in your page that's causing the problem?
Jan 3 '09 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Rob | last post by:
THis is my code. What im trying to accomplish is the user fills out the form then when they hit submit it displays what the entered on the samne page but i get this error message when I hit submit...
4
by: mickbw | last post by:
I am unable to display PHP pages generated by a submission of a form using a POST method. To illustrate this, I created a very simple form called TestForm.php . <!DOCTYPE html PUBLIC...
1
by: | last post by:
A friend of mine has a website that is ASP. I know nothing about ASP. He switched hosting and now his "contact us" form does not work. When you hit submit it gives an error "Error 405 Method not...
5
by: RK | last post by:
I am getting the "HTTP /1.1 405 - method not allowed" error when I am sending XML string over Msxml2.XMLHTTP object. I am sending data in POST, also passing querystring variable and here is the...
2
by: GlennLanier | last post by:
Hello, I've searched the forums and can't find an answer -- if it i there, kindly point me in that direction. I would like to simulate a browser POSTing a FORM and be able to pars the response....
0
by: Luis Esteban Valencia | last post by:
Hello I got this program and this error. Unable to complete web request. Web Exception error: Error en el servidor remoto: (405) Método no permitido Its supposed to send xml messages to a...
0
by: John | last post by:
Hi, I am getting this error message The remote server returned an error: (405) Method Not Allowed. while trying to execute the following code: Dim myReq As HttpWebRequest =...
23
by: Bjorn | last post by:
Hi. Every time i post data in a form the contents are being checked for validity. When i click the back-button, all data is gone and i have to retype it. It's obvious that only a few or none of...
8
by: Kurda Yon | last post by:
Hi, I have to decide which form-method I should use (GET or POST). I found the following recomendation: If the service associated with the processing of a form has side effects (for example,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.