Javascript 如何通过多次单击添加图标添加图像
下面的代码用户可以通过按ctrl键单击图标发送多个图像。但这不是我想要的。相反,用户可以多次单击同一图标,每次添加一个图像。例如,在SO提问页面中,用户可以多次单击同一个“添加图像”图标以添加多个图像。如何实现这一点Javascript 如何通过多次单击添加图标添加图像,javascript,jquery,html,Javascript,Jquery,Html,下面的代码用户可以通过按ctrl键单击图标发送多个图像。但这不是我想要的。相反,用户可以多次单击同一图标,每次添加一个图像。例如,在SO提问页面中,用户可以多次单击同一个“添加图像”图标以添加多个图像。如何实现这一点 <!-- This is not what I want. Each time one image will be added by clicking the same uploader, rather than by pressing ctrl. -->
<!-- This is not what I want. Each time one image will be added by clicking
the same uploader, rather than by pressing ctrl.
-->
<form action="storeArticle" method="post" enctype="multipart/form-data">
<input type="file" name="file" multiple onchange="previewFile()"><br/>
<input type="submit" name="submit" class="submit" id="submit" value="submit" />
</form>
pot更多的代码..pot更多的代码。。