代码如下:<form name=Myform onsubmit=”return CheckFileSize()”> <input type=file name=photo> <input type=submit value=submit></form> [removed]<!– function CheckFileSize() { var s = document.Myform.photo.value;