Merge branch 'contrib/github_pr_15023' into 'master'

fix(html): Fix upload_script to actually use max size variables (GitHub PR)

Closes IDFGH-14227

See merge request espressif/esp-idf!35803
This commit is contained in:
Mahavir Jain
2024-12-23 15:57:37 +08:00

View File

@@ -49,8 +49,8 @@ function upload() {
alert("File path on server cannot have spaces!"); alert("File path on server cannot have spaces!");
} else if (filePath[filePath.length-1] == '/') { } else if (filePath[filePath.length-1] == '/') {
alert("File name not specified after path!"); alert("File name not specified after path!");
} else if (fileInput[0].size > 200*1024) { } else if (fileInput[0].size > MAX_FILE_SIZE) {
alert("File size must be less than 200KB!"); alert("File size must be less than "+MAX_FILE_SIZE_STR+"!");
} else { } else {
document.getElementById("newfile").disabled = true; document.getElementById("newfile").disabled = true;
document.getElementById("filepath").disabled = true; document.getElementById("filepath").disabled = true;