Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


Upload functionality using HTML

Posted on 2009-12-21
Medium Priority
Last Modified: 2013-12-25
I am testing our new URL ( HTTPS ) and would like to have the code to upload a file to HTTPS server. Below is the page I am using to upload the file...

<form action="https://testserver"
enctype="multipart/form-data" method="post">
Type some text (if you like):<br>
<input type="text" name="textline" size="30">
Please specify a file, or a set of files:<br>
<input type="file" name="datafile" size="40">
<input type="submit" value="Send">
Question by:g46905
  • 4
  • 3
LVL 10

Expert Comment

ID: 26099608
That is well-formed HTML for the task you described.

What exactly is your question?

Author Comment

ID: 26099661
When I use that page and try to upload the file, I get the following error...

The page you are looking for cannot be displayed because an invalid method (HTTP verb) was used to attempt access.

Please try the following:

Contact the Web site administrator if you believe that this request should be allowed.
Make sure that the Web site address displayed in the address bar of your browser is spelled and formatted correctly.
HTTP Error 405 - The HTTP verb used to access this page is not allowed.
Internet Information Services (IIS)
LVL 10

Expert Comment

ID: 26099750
Does the IIS server support https?

Try http://testserver and see if you get the same error.

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.


Author Comment

ID: 26099751
I am looking for a servlet that can use the GET method parameters to decide what to do with the upload while the POST body of the request contains the file data to parse.


Author Comment

ID: 26099776
Our IIS server supports HTTPS. As I mentioned in me earlier post, I would need a servlet that must process the POST data in order to extract the encoded file
LVL 10

Expert Comment

ID: 26099783
The "GET" parameters appear in the URL after the question mark.

Look at this article for information on access environment variables:

You will find the "GET" parameters in the environment variable QUERY_STRING.
LVL 10

Accepted Solution

tdlewis earned 2000 total points
ID: 26099822
OK, but that doesn't explain "HTTP Error 405 - The HTTP verb used to access this page is not allowed."

See this article for information on parsing posted files in an IIS server:

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses four methods for overlaying images in a container on a web page
It’s a season to be thankful, and we’re thankful for users like you who engage on site, solve technology problems, and network with others in the industry. What tech are we most thankful for? Keep reading.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses

571 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question