form_file_upload.html 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>H+ 后台主题UI框架 - 文件上传</title>
  7. <meta name="keywords" content="H+后台主题,后台bootstrap框架,会员中心主题,后台HTML,响应式后台">
  8. <meta name="description" content="H+是一个完全响应式,基于Bootstrap3最新版本开发的扁平化主题,她采用了主流的左右两栏式布局,使用了Html5+CSS3等现代技术">
  9. <link rel="shortcut icon" href="favicon.ico"> <link href="css/bootstrap.min.css?v=3.3.7" rel="stylesheet">
  10. <link href="css/font-awesome.css?v=4.4.0" rel="stylesheet">
  11. <link href="css/animate.css" rel="stylesheet">
  12. <link href="css/plugins/dropzone/basic.css" rel="stylesheet">
  13. <link href="css/plugins/dropzone/dropzone.css" rel="stylesheet">
  14. <link href="css/style.css?v=4.1.0" rel="stylesheet">
  15. </head>
  16. <body class="gray-bg">
  17. <div class="wrapper wrapper-content animated fadeIn">
  18. <div class="row">
  19. <div class="col-sm-12">
  20. <div class="ibox float-e-margins">
  21. <div class="ibox-title">
  22. <h5>文件上传</h5>
  23. <div class="ibox-tools">
  24. <a class="collapse-link">
  25. <i class="fa fa-chevron-up"></i>
  26. </a>
  27. <a class="dropdown-toggle" data-toggle="dropdown" href="form_file_upload.html#">
  28. <i class="fa fa-wrench"></i>
  29. </a>
  30. <ul class="dropdown-menu dropdown-user">
  31. <li><a href="form_file_upload.html#">选项1</a>
  32. </li>
  33. <li><a href="form_file_upload.html#">选项2</a>
  34. </li>
  35. </ul>
  36. <a class="close-link">
  37. <i class="fa fa-times"></i>
  38. </a>
  39. </div>
  40. </div>
  41. <div class="ibox-content">
  42. <form id="my-awesome-dropzone" class="dropzone" action="form_file_upload.html#">
  43. <div class="dropzone-previews"></div>
  44. <button type="submit" class="btn btn-primary pull-right">提交</button>
  45. </form>
  46. <div>
  47. <div class="m"><small>DropzoneJS是一个开源库,提供拖放文件上传与图片预览:<a href="https://github.com/enyo/dropzone" target="_blank">https://github.com/enyo/dropzone</a></small>,百度前端团队提供的<a href="http://fex.baidu.com/webuploader/" target="_blank">Web Uploader</a>也是一个非常不错的选择,值得一试!</div>
  48. </div>
  49. </div>
  50. </div>
  51. </div>
  52. </div>
  53. </div>
  54. <!-- 全局js -->
  55. <script src="js/jquery.min.js?v=2.1.4"></script>
  56. <script src="js/bootstrap.min.js?v=3.3.7"></script>
  57. <!-- 自定义js -->
  58. <script src="js/content.js?v=1.0.0"></script>
  59. <!-- DROPZONE -->
  60. <script src="js/plugins/dropzone/dropzone.js"></script>
  61. <script>
  62. $(document).ready(function () {
  63. Dropzone.options.myAwesomeDropzone = {
  64. autoProcessQueue: false,
  65. uploadMultiple: true,
  66. parallelUploads: 100,
  67. maxFiles: 100,
  68. // Dropzone settings
  69. init: function () {
  70. var myDropzone = this;
  71. this.element.querySelector("button[type=submit]").addEventListener("click", function (e) {
  72. e.preventDefault();
  73. e.stopPropagation();
  74. myDropzone.processQueue();
  75. });
  76. this.on("sendingmultiple", function () {});
  77. this.on("successmultiple", function (files, response) {});
  78. this.on("errormultiple", function (files, response) {});
  79. }
  80. }
  81. });
  82. </script>
  83. <script type="text/javascript" src="http://tajs.qq.com/stats?sId=9051096" charset="UTF-8"></script>
  84. <!--统计代码,可删除-->
  85. </body>
  86. </html>