CopyNMoveUI.php 2.8 KB

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