upload.html fixes
Minor modifications so it works without zipping and without compiling lua. Fits well on WEMOS D1 Pro - we’ll see if anyone complains.
This commit is contained in:
parent
d27251c698
commit
87e1a4babc
1
http/hello_world.txt
Normal file
1
http/hello_world.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
Hello World!
|
||||||
@ -29,7 +29,7 @@
|
|||||||
<li><a href="node_info.lua">NodeMCU info</a>: Shows some basic NodeMCU(Lua)</li>
|
<li><a href="node_info.lua">NodeMCU info</a>: Shows some basic NodeMCU(Lua)</li>
|
||||||
<li><a href="file_list.lua">List all server files</a>: Displays a list of all the server files. (Lua)</li>
|
<li><a href="file_list.lua">List all server files</a>: Displays a list of all the server files. (Lua)</li>
|
||||||
<li><a href="foo.html">Foo</a>: A file that doesn't exist. Should error (404 error)</li>
|
<li><a href="foo.html">Foo</a>: A file that doesn't exist. Should error (404 error)</li>
|
||||||
<li><a href="upload.html">Upload</a>: update, remove, list files on the server.</li>
|
<li><a href="upload.html">Upload</a>: update, remove, list files on the server. By <a href="https://github.com/ATAMAH">ATAMAH</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@ -396,7 +396,7 @@
|
|||||||
fileUploadRequest = 0;
|
fileUploadRequest = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
lastRequest = 'upload.lc?cmd=upload&filename=' + file.name + '&filesize=' + file.size + '&len=' + chunkLen + '&offset=' + sendingOffset + '&data=' + filedata;
|
lastRequest = 'upload.lua?cmd=upload&filename=' + file.name + '&filesize=' + file.size + '&len=' + chunkLen + '&offset=' + sendingOffset + '&data=' + filedata;
|
||||||
|
|
||||||
fileUploadRequest.timeout = 5000;
|
fileUploadRequest.timeout = 5000;
|
||||||
fileUploadRequest.open('GET', lastRequest, true);
|
fileUploadRequest.open('GET', lastRequest, true);
|
||||||
@ -526,7 +526,7 @@
|
|||||||
fileListRequest = null;
|
fileListRequest = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
fileListRequest.open('GET', 'upload.lc?cmd=list', true);
|
fileListRequest.open('GET', 'upload.lua?cmd=list', true);
|
||||||
fileListRequest.send();
|
fileListRequest.send();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -541,7 +541,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fileRemoveRequest.open('GET', 'upload.lc?cmd=remove&filename=' + name, true);
|
fileRemoveRequest.open('GET', 'upload.lua?cmd=remove&filename=' + name, true);
|
||||||
fileRemoveRequest.send();
|
fileRemoveRequest.send();
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user