简体   繁体   English

Mysql和php-拖放图像在数据库中上传

[英]Mysql and php- drag and drop image to upload in database

是否可以使用php拖放图像将图片上传到数据库?

If you use a front end library (Javascript) to catch the event of dropping the object into the page, and then submitting it via an Ajax request - yes it is possible. 如果您使用前端库(Javascript)来捕获将对象放入页面的事件,然后通过Ajax请求提交它 ​​- 是的,这是可能的。 The other (uglier) route is to have a Java applet that does it (still through ajax). 另一个(丑陋的)路由是有一个Java applet来做它(仍然是通过ajax)。

I wouldnt store the images in the database though. 我不会将图像存储在数据库中。 Store them in a filesystem with the path specifics stored in the DB. 将它们存储在文件系统中,路径细节存储在DB中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM