Saved X
Google login
SignUp with Email
X

Get file size before uploading

theindreshverma ( Edited  26 Oct 2021, 01:06 am )
Login

<input type="file" name="file" id="file">

<script type="text/javascript">
$(document).ready(function() {       
    $('#file').change(function() {
        var fileSize = (this.files[0].size); 
        alert(fileSize/1024 + "Kb");
    });
});
</script>

More Sourcecodes

More Sourcecodes