index.html 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. <!doctype html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <link rel="shortcut icon" type="image/x-icon" href="./favicon.ico" media="screen" />
  6. <title>JavaScript SDK</title>
  7. <style>
  8. tr{
  9. padding: 10px;
  10. }
  11. th,td{
  12. margin-right:40px;
  13. width: 200px;
  14. text-align: center;
  15. }
  16. th,td:first-child{
  17. width: 300px;
  18. }
  19. #exampleForDeleteFile .del-opt {
  20. text-decoration: underline;
  21. color: red;
  22. }
  23. </style>
  24. </head>
  25. <body>
  26. <ul id="filelist"></ul>
  27. <br />
  28. <div id="container">
  29. <a id="browse" href="javascript:;">[Browse...]</a>
  30. <a id="start-upload" href="javascript:;">[Start Upload]</a>
  31. </div>
  32. <div id="example2">
  33. <button id="get-bucket" style="margin: 30px 0;">List Objects</button>
  34. <textarea id="responsexml" style="width: 80%;height: 400px; margin:0px 10%;"></textarea>
  35. </div>
  36. <div id="example3" style="margin-top:20px;">
  37. <input type="file" id="imgFile">
  38. <progress id="progressBar" value="0" max="100"> </progress>
  39. <button id="utp" style="margin-left: 3em">Upload Trigger Processing</button>
  40. <div id="display-adp-result" style="margin-top: 1em"><img src=""></div>
  41. </div>
  42. <div id="example4" style="margin-top:20px;">
  43. <input type="file" id="imgFile2">
  44. <progress id="progressBar2" value="0" max="100"> </progress>
  45. <button id="utp2" style="margin-left: 3em">Put上传</button>
  46. <div id="display-adp-result2" style="margin-top: 1em"><img src=""></div>
  47. </div>
  48. <table id="exampleForDeleteFile" style="margin-top:20px;">
  49. <tr><th>文件名</th><th>大小</th><th>最后更新时间</th><th>操作</th></tr>
  50. </table>
  51. <div id="exampleForDownloadFile" style="margin-top:20px; color: darkred">
  52. <span>http://sanrui.kss.ksyun.com/jssdk/book.pdf</span>
  53. <button id="downloadBigFileBtn" style="margin-left:1em;">下载大文件</button>
  54. <progress id="downloadProgressBar" value="0" max="100" style="margin-left: 2em;width: 300px"></progress>
  55. <span style="margin-left:10px" id="downloadPercent"></span>
  56. <button id="stopDownload" style="margin:0 2em">暂停</button>
  57. </div>
  58. <div id="multipartUpload" style="margin: 30px 0;">
  59. <!--<input type="file" id="bigFile" webkitdirectory>-->
  60. <input type="file" id="bigFile">
  61. <button id="uploadBigFile">分块上传</button>
  62. <progress id="multipartUploadProgressBar" value="0" max="100" style="margin:0 2em;width: 300px"> </progress>
  63. <button id="suspendMultipartUpload">暂停</button>
  64. <button id="cancelMultipartUpload" style="margin:0 10px">取消</button>
  65. </div>
  66. <script type="text/javascript" src="js/plupload.full.min.js"></script>
  67. <script type="text/javascript" src="js/ks3jssdk.js"></script>
  68. <script type="text/javascript" src="lib/async.min.js"></script>
  69. <script type="text/javascript" src="js/main.js"></script>
  70. </body>
  71. </html>