Method Not Allowed / The requested method POST is not allowed for the URL

Method Not Allowed / The requested method POST is not allowed for the URL

 

Really a very interesting and common problem I found today. The solution is more interesting than the Problem.  

This error can occur in several situations. The following list includes some of the most common reasons developers encounter this issue:    

  • The action attribute of a form does not point to an executable script or there is no file specified for the action (in which case, the action field in the Property inspector is blank). 
  • The form’s action attribute points to an HTML file. 
  • A developer saves web pages with an HTM or HTML file extension instead of ASP, PHP, CFM or JSP file extensions, and specifies HTM or HTML as the default file extension in the site definition.

Things to look for when receiving this error:

  • Specify an action attribute in the form’s Property inspector
    The action field cannot be left blank and must specify an executable file. Common valid file types for the form action attribute include ASP, JSP, CFM, PHP, EXE, DLL or CGI. If you use one of Dreamweaver’s application objects—such as an Insert Record or Update Record—you may instead see a variable similar to <%=MM_editAction%> .
  • Check file extension of the web page producing the error
    The page must have a file extension of ASP, PHP, ASPX, CFM or JSP. If the page has an extension of HTM or HTML, it will need to be renamed with the default extension for the server model specified in the site definition.
  • Check that the correct page type is specified in the site definition
    Check the server model field in the Testing Server category of the site definition. The server model should match the correct language.

Another solution:

PHP: This is almost always due to Apache not being configured to treat the file you are trying to POST to as a CGI script. You can not POST to a normal HTML file; the operation has no meaning.

Please visit to find the solution: http://www.somacon.com/p126.php

One most important thing is that ”your web server must support the php, asp or cgi whatever scripting language you are using”. Please check is your web server support the scripting language you are using in your web site else it can generate this error. This is one of the major issue found in various problem. So plz check your web server. 

If you feel this blog gives you a proper solution, please post your comments. 

Regards,
Vijay Modi

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值