• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Http error status 405

 
Ranch Hand
Posts: 106
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying a upload program which passes parameters to a servlet .
I have tried a long time but still not solve it.
Anyone knows how to do?
Thanks a lot.
The error is following:
HTTP Status 405 - HTTP method POST is not supported by this URL
message HTTP method POST is not supported by this URL
description The specified HTTP method is not allowed for the requested resource (HTTP method POST is not supported by this URL).
 
Ranch Hand
Posts: 645
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
If you have and have defined you form tag as ..<form action="....." method=post>
then your servle must have doPost method
Cheers
Praful
 
Sophia Choi
Ranch Hand
Posts: 106
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I did. What other possibilities? Does it relate to the servlet configuration?
Thanks
public void doPost(HttpServletRequest req,HttpServletResponse res) throws ServletException,IOException{
....
 
Ranch Hand
Posts: 472
Objective C Ubuntu Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Wait a minute. Are you doing upload program?
Do you have in form header:
method="post" enctype="multipart/form-data"
?
Do you use apache or some other implementation to parse parameters?
 
Sophia Choi
Ranch Hand
Posts: 106
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
of course, my jsp has the enctype like the following:
form name="form1" enctype="multipart/form-data" method="post"
onSubmit="return validateForm(this)" action="/cfhc/servlet/UploadTest"
The program can work in the office.In my office, I have the Tomcat 4.1 only.
But, this cannot work at home. I have installed IIS and Tomcat. But they are in different port.I have changed the port of Tomcat to 8081.
Is it the source of the problem?
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic