Ian is right. It doesnt matter what language you use, you are
still limited to what http standards allow and do.
One thing you could try using is see what the
cgi.content_length is of the file. It will check to see the size of
the content header being passed to the page or code that doing your
file upload.
YET this is not the most accurate or reliable way to check
file size, AND it will only really work if you are uploading one
file at a time. If you do multiple files, it will add them all up
in one lump sum and you wont be able to tell individual file sizes.
Flash 8 is one of the better ways to do it client side, which
is what you would be trying to acheive. ASFUSION has some great
tutorials and working downloadable examples on doing Flash file
uploads, and I believe that they check for file size and type prior
to uploading
http://www.asfusion.com/examples/item/file-upload-with-coldfusion-flash-forms