Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   HTML (http://www.velocityreviews.com/forums/f31-html.html)
-   -   will the following html code submit the contents of the file? (http://www.velocityreviews.com/forums/t156094-will-the-following-html-code-submit-the-contents-of-the-file.html)

Guy 12-05-2003 04:08 AM

will the following html code submit the contents of the file?
 
Believe it or not, I never saw the file-type input tag until tonight.
I didn't know you could have a browse button on an HTML document!

So now, I'd like to submit a file to our server.
In my initial tests, I am attaching a text file containing only about 20
characters.

Is this how it works?
Will the following code submit the file content after I select the file with
the browse button and click the submit button.

Also, what does the accept parameter do?

Thanks for all,
Guy D


<HTML>
<BODY>
<FORM name=sendmsg method=POST enctype="multipart/form-data"
action="cgi-bin/test.pl">

<INPUT type=file size=40 name=af accept="*/*">
<INPUT type=submit>

</FORM>
</BODY>
</HTML>



brucie 12-05-2003 06:20 AM

Re: will the following html code submit the contents of the file?
 
in post <news:7xTzb.4934$IF6.237107@ursa-nb00s0.nbnet.nb.ca>
Guy said:


> So now, I'd like to submit a file to our server.


File input (or "upload") in HTML forms
http://www.cs.tut.fi/~jkorpela/forms/file.html


--
brucie
05/December/2003 04:20:27 pm kilo

Hywel Jenkins 12-05-2003 03:48 PM

Re: will the following html code submit the contents of the file?
 
"Guy" <someone@somewhere.nb.ca> wrote in message news:<7xTzb.4934$IF6.237107@ursa-nb00s0.nbnet.nb.ca>...
> So now, I'd like to submit a file to our server.
> In my initial tests, I am attaching a text file containing only about 20
> characters.
>
> Is this how it works?


Is that how what works?


> Will the following code submit the file content after I select the file with
> the browse button and click the submit button.


Yes.


> Also, what does the accept parameter do?


Usually, nothing. It's supposed to set the filter in the file dialog.

--
Hywel


All times are GMT. The time now is 04:41 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.