File Upload Size Validation
问题 Validations are a big problem, as if i validate in php it has all the functions etc i need to make it work.. But it uploads the file first on a temporary location and then checks, which sucks. If someone uploads a file of 100mb he has to wait for the time just to get no error, but just some internal php screw up hanging the page. One Way: JS //file is id of input file alert(document.getElementById('file').files[0].fileSize); This works in firefox, safari, chrome i guess too, NOT: In opera,