CopyNMoveUI.php 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <script src="../script/jquery.min.js"></script>
  6. <!-- <script src="../script/jquery-ui.min.js"></script> -->
  7. <link rel="stylesheet" href="../script/tocas/tocas.css">
  8. <script type='text/javascript' src="../script/tocas/tocas.js"></script>
  9. <script type='text/javascript' src="../script/ao_module.js"></script>
  10. <title>7z File Manager</title>
  11. <style>
  12. body{
  13. background-color:white
  14. }
  15. .ts.form .inline.field label {
  16. min-width: 50%;
  17. }
  18. .ts.basic.dropdown, .ts.form select {
  19. max-width: 50%;
  20. }
  21. </style>
  22. </head>
  23. <body>
  24. <div class="ts container">
  25. <div class="ts grid">
  26. <div class="sixteen wide column">
  27. <br>
  28. <div class="ts form">
  29. <div class="field">
  30. <label>Copy to:</label>
  31. <div class="ts labeled input" style="width:100%">
  32. <div class="ts label">
  33. /AOR/
  34. </div>
  35. <input type="text" id="path" placeholder="Path here">
  36. </div>
  37. </div>
  38. </div>
  39. </div>
  40. <div class="sixteen wide column">
  41. <p id="filesshow">
  42. Extract to:
  43. </p>
  44. </div>
  45. <div class="eight wide column"></div>
  46. <div class="eight wide column">
  47. <button class="ts basic button" style="width:45%" onclick="f_ok()">OK</button>
  48.     
  49. <button class="ts basic button" style="width:45%" onclick="f_close()">Cancel</button>
  50. </div>
  51. </div>
  52. </div>
  53. </body>
  54. <script>
  55. var f_method = "<?php echo $_GET["method"] ?>";
  56. var f_rand = "<?php echo $_GET["rand"] ?>";
  57. var f_file = "<?php echo $_GET["file"] ?>";
  58. var f_dir = "<?php echo $_GET["dir"] ?>";
  59. var f_extractTo = "";
  60. function f_close(){
  61. if(ao_module_virtualDesktop){
  62. ao_module_close();
  63. }else{
  64. ts('#modal').modal('hide');
  65. }
  66. }
  67. function f_ok(){
  68. var href = "ProgressUI.php?method=" + f_method + "&rand=" + f_rand + "&file=" + f_file + "&dir=" + f_dir + "&destdir=" + f_extractTo;
  69. if(ao_module_virtualDesktop){
  70. ao_module_newfw('7-Zip File Manager/' + href,'7-Zip','file outline','7-ZipProgressUI' + Math.floor(Math.random()*100),720,250);
  71. ao_module_close();
  72. }else{
  73. $.get( href, function( data ) {
  74. $( "#modaldata" ).html( data );
  75. ts('#modal').modal("show");
  76. });
  77. }
  78. }
  79. $( "#path" ).keyup(function() {
  80. var path = $("#path").val();
  81. var displayPath = "";
  82. if(f_dir == ""){
  83. displayPath = "...";
  84. }else{
  85. if(f_method == "e"){
  86. displayPath = f_dir.replace(/^.*[\\\/]/, '');
  87. }else{
  88. displayPath = f_dir;
  89. }
  90. }
  91. if(path.slice(-1) !== "/"){
  92. path = path + "/";
  93. }
  94. $("#filesshow").text("Extract to: /AOR/" + path + f_file.replace(/^.*[\\\/]/, '').replace(".","") + "/" + displayPath);
  95. f_extractTo = "../" + path;
  96. });
  97. /* still in implmention
  98. $( "#path" ).keypress(function() {
  99. $.get( "opr.php?method=ListAORDir&dir=" + $( "#path" ).val(), function( data ) {
  100. $( "#path" ).autocomplete({
  101. source: JSON.parse(data)
  102. });
  103. });
  104. });
  105. */
  106. </script>
  107. </html>