I see, so under what circumstances would the code I have written above work - I presumed it would let a client upload files to a server, but I also felt it looked much too easy - this is my first time doing any file uploading!. I wrote this code because I want to allow people to upload files to my server - these files will eventually be organised using MySql. WHat modifications will I need to make - security is a big issue too - is it possible to give someone enough access in order for them to upload a file without compromising server security - im sure it is.
Anyway Thanks,
Barry.
This is the html I'm using to call the script -
<HTML><BODY>
<FORM ENCTYPE="multipart/form-data" ACTION="http://baz.perlmonk.org/co
+okie.cgi" METHOD="POST">
Please choose directory to upload to:<br>
<SELECT NAME="dir">
<OPTION VALUE="images">images</OPTION>
<OPTION VALUE="sounds">sounds</OPTION>
</SELECT>
<p>
Please select a file to upload: <BR>
<INPUT TYPE="FILE" NAME="file">
<p>
<INPUT TYPE="submit">
</FORM>
</HTML></BODY>
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.