Trust me - your script's fine. I tested it on two platforms and it works...ermmm - you *are* only uploading files of less than 4k, aren't you? If not, you need to remove / increase the value of $CGI::POST_MAX.
There's no difference between using a hand-crafted HTML form and using a CGI.pm generated one - the end result is exactly the same - a bunch of HTML that posts some data. Try using "print $fdata->Dump()" to show you exactly what params were posted.
In cases like this, it's always tempting to blame something else - "There's a bug in CGI.pm" or "The server's broken"...again, trust me...99.999% of the time, it's your code. If there was really a problem with something as basic as file uploading in CGI.pm, it'd have been found by now.
Cheers,
Ben
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.