Ive writen a scipt that allows a client upload mp3s to my server, but Ive seen some browser upload done in the following fashion
while (my $bytesread = read($filesource, my $buffer,1024))
{
print OUTFILE $buffer;
}
My code is similar to the above code except for the 1024. What is its purpose?. Are the blocks transfered in 1KB packets - and if so that would be the best block size for uploading mp3s
Also, at the moment when the client selects a file and hits the upload button, the browser hangs until the file is fully transferred and only then does the next page display notifying the client that the transfer was successful - is there anyway of giving a progress report will a file is uploading - the status bar at the bottom of an IE4 window gives no reflexion of how much long the file will take to transfer.
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.