如何拖拽文件到指定位置,具体方法如下
在从本地上传图片的时候,如果使用拖拽效果,想想应该是更加的高大上,下面直接上代码
完整代码:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style>
#dropBox{
width: 300px;
height: 300px;
border:1px solid red;
font-size: 40px;
text-align: center;
background: light