I want to save bandwidth and restrict the size of uploaded files to our webpage. The problem is that I can set the maximal size of uploaded file (e.g., 1 MB) but a user can select 50 MB file and can upload it to find out that PHP really doesn't accept files of this size -- the uploading is totally unnecessary.
Can I prevent this somehow?
(I can check file size in Javascript but not all browsers support this. Flash is an option but it's not universal either).
Thanks!