英文:
Is There a Way To Handle Files Locally Without Using php
问题
I'm designing a web app (HTML/CSS/JS) that will run natively on my computer which I want to use to handle local files on my computer (like images and stuff like that.) I understand the use of php scripts and other browser security for a website running online, but is there an easier way to handle it if I'm running the application from my computer?
All I want to be able to do is browse my computer for files, "upload" those files to the web app (copy them into the relative path of the application), mess around and do various things with them, and then save them to a customizable path back onto my computer.
If there is not an easier way to do this, I would also accept suggestions about where to start with file management, I'm new to that area of web design.
Thanks!
英文:
I'm designing a web app (HTML/CSS/JS) that will run natively on my computer which I want to use to handle local files on my computer (like images and stuff like that.) I understand the use of php scripts and other browser security for a website running online, but is there an easier way to handle it if I'm running the application from my computer?
All I want to be able to do is browse my computer for files, "upload" those files to the web app (copy them into the relative path of the application), mess around and do various things with them, and then save them to a customizable path back onto my computer.
If there is not an easier way to do this, I would also accept suggestions about where to start with file management, I'm new to that area of web design.
Thanks!
答案1
得分: 1
你可以使用带有文件类型的 input
元素,然后你可以使用 File
API 操作文件。
如果你需要获取文件的路径,你可以使用 Electron 与 Node 的 文件系统 API 结合使用。
英文:
You can use an input
element with a type of file then you can manipulate the file using the File
API.
If you need to have the paths of the files, you can use Electron in conjunction with Node's filesystem API.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论