瀏覽代碼

Correct indentation

Flat 9 年之前
父節點
當前提交
c57e10156e

+ 19 - 19
web/templates/admin/add_db.js.html

@@ -1,21 +1,21 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                randomstring += chars.substr(rnum, 1);
-            }
-            document.v_add_db.v_password.value = randomstring;
-        }
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_add_db.v_password.value = randomstring;
+    }
 
-        GLOBAL.DB_USER_PREFIX = <?=json_encode($user.'_')?>;
-        GLOBAL.DB_DBNAME_PREFIX = <?=json_encode($user.'_')?>;
-    </script>
-    <script src="/js/pages/add.db.js"></script>
+    GLOBAL.DB_USER_PREFIX = <?=json_encode($user.'_')?>;
+    GLOBAL.DB_DBNAME_PREFIX = <?=json_encode($user.'_')?>;
+  </script>
+  <script src="/js/pages/add.db.js"></script>

+ 31 - 31
web/templates/admin/add_dns.js.html

@@ -1,35 +1,35 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        $(document).ready(function(){
-            $('.add-ns-button').click(function(){
-              var n = $("input[name^=v_ns]").length;
-              if(n < 8){
-                var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
-                t.find('input').attr({value:'', name:'v_ns'+(n+1)});
-                t.find('span').show();
-                $('tr.add-ns').before(t);
-              }
-              if( n == 7 ) {
-                $('.add-ns').hide();
-              }
-            });
+    $(document).ready(function(){
+      $('.add-ns-button').click(function(){
+        var n = $("input[name^=v_ns]").length;
+        if(n < 8){
+        var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
+        t.find('input').attr({value:'', name:'v_ns'+(n+1)});
+        t.find('span').show();
+        $('tr.add-ns').before(t);
+        }
+        if( n == 7 ) {
+        $('.add-ns').hide();
+        }
+      });
 
-            $('.remove-ns').click(function(){
-                $(this).parents('tr')[0].remove();
-                $('input[name^=v_ns]').each(function(i, ns){
-                    $(ns).attr({name: 'v_ns'+(i+1)});
-                    i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-                })
-                $('.add-ns').show()
-            })
+      $('.remove-ns').click(function(){
+        $(this).parents('tr')[0].remove();
+        $('input[name^=v_ns]').each(function(i, ns){
+          $(ns).attr({name: 'v_ns'+(i+1)});
+          i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+        })
+        $('.add-ns').show()
+      })
 
-            $('input[name^=v_ns]').each(function(i, ns){
-              i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-            })
+      $('input[name^=v_ns]').each(function(i, ns){
+        i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+      })
 
-        });
-    </script>
+    });
+  </script>

+ 4 - 4
web/templates/admin/add_dns_rec.js.html

@@ -1,4 +1,4 @@
-    <script>
-        GLOBAL.DNS_REC_PREFIX = <?=json_encode($_GET['domain'])?>;
-    </script>
-    <script src="/js/pages/add.dns.record.js"></script>
+  <script>
+    GLOBAL.DNS_REC_PREFIX = <?=json_encode($_GET['domain'])?>;
+  </script>
+  <script src="/js/pages/add.dns.record.js"></script>

+ 6 - 6
web/templates/admin/add_firewall.js.html

@@ -1,6 +1,6 @@
-    <script>
-        function elementHideShow(elementToHideOrShow) {
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
-    </script>
+  <script>
+    function elementHideShow(elementToHideOrShow) {
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
+  </script>

+ 6 - 6
web/templates/admin/add_firewall_banlist.js.html

@@ -1,6 +1,6 @@
-    <script>
-        function elementHideShow(elementToHideOrShow) {
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
-    </script>
+  <script>
+    function elementHideShow(elementToHideOrShow) {
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
+  </script>

+ 6 - 6
web/templates/admin/add_ip.js.html

@@ -1,6 +1,6 @@
-    <script>
-        function elementHideShow(elementToHideOrShow) {
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
-    </script>
+  <script>
+    function elementHideShow(elementToHideOrShow) {
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
+  </script>

+ 40 - 40
web/templates/admin/add_mail_acc.js.html

@@ -1,46 +1,46 @@
-    <script>
-        function elementHideShow(elementToHideOrShow) {
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+  <script>
+    function elementHideShow(elementToHideOrShow) {
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-              var rnum = Math.floor(Math.random() * chars.length);
-              randomstring += chars.substr(rnum, 1);
-            }
-            document.v_add_mail_acc.v_password.value = randomstring;
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_add_mail_acc.v_password.value = randomstring;
 
-            if($('input[name=v_password]').attr('type') == 'text')
-              $('#v_password').text(randomstring);
-            else
-              $('#v_password').text(Array(randomstring.length+1).join('*'));
-        }
+      if($('input[name=v_password]').attr('type') == 'text')
+        $('#v_password').text(randomstring);
+      else
+        $('#v_password').text(Array(randomstring.length+1).join('*'));
+    }
 
-        $(document).ready(function() {
-            $('#v_account').text($('input[name=v_account]').val());
-            $('#v_password').text($('input[name=v_password]').val());
+    $(document).ready(function() {
+      $('#v_account').text($('input[name=v_account]').val());
+      $('#v_password').text($('input[name=v_password]').val());
 
-            $('input[name=v_account]').change(function(){
-              $('#v_account').text($(this).val());
-            });
+      $('input[name=v_account]').change(function(){
+        $('#v_account').text($(this).val());
+      });
 
-            $('input[name=v_password]').change(function(){
-              if($('input[name=v_password]').attr('type') == 'text')
-                $('#v_password').text($(this).val());
-              else
-                $('#v_password').text(Array($(this).val().length+1).join('*'));
-            });
+      $('input[name=v_password]').change(function(){
+        if($('input[name=v_password]').attr('type') == 'text')
+        $('#v_password').text($(this).val());
+        else
+        $('#v_password').text(Array($(this).val().length+1).join('*'));
+      });
 
-            $('.toggle-psw-visibility-icon').click(function(){
-              if($('input[name=v_password]').attr('type') == 'text')
-                $('#v_password').text($('input[name=v_password]').val());
-              else
-                $('#v_password').text(Array($('input[name=v_password]').val().length+1).join('*'));
-            });
-        });
-    </script>
-    <script src="/js/pages/edit.package.js"></script>
+      $('.toggle-psw-visibility-icon').click(function(){
+        if($('input[name=v_password]').attr('type') == 'text')
+        $('#v_password').text($('input[name=v_password]').val());
+        else
+        $('#v_password').text(Array($('input[name=v_password]').val().length+1).join('*'));
+      });
+    });
+  </script>
+  <script src="/js/pages/edit.package.js"></script>

+ 28 - 28
web/templates/admin/add_package.js.html

@@ -1,30 +1,30 @@
-    <script>
-        $(document).ready(function(){
-            $('.add-ns-button').click(function(){
-              var n = $("input[name^=v_ns]").length;
-              if(n < 8){
-                var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
-                t.find('input').attr({value:'', name:'v_ns'+(n+1)});
-                t.find('span').show();
-                $('tr.add-ns').before(t);
-              }
-              if( n == 7 ) {
-                $('.add-ns').hide();
-              }
-            });
+  <script>
+    $(document).ready(function(){
+      $('.add-ns-button').click(function(){
+        var n = $("input[name^=v_ns]").length;
+        if(n < 8){
+        var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
+        t.find('input').attr({value:'', name:'v_ns'+(n+1)});
+        t.find('span').show();
+        $('tr.add-ns').before(t);
+        }
+        if( n == 7 ) {
+        $('.add-ns').hide();
+        }
+      });
 
-            $('.remove-ns').click(function(){
-                $(this).parents('tr')[0].remove();
-                $('input[name^=v_ns]').each(function(i, ns){
-                    $(ns).attr({name: 'v_ns'+(i+1)});
-                    i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-                })
-                $('.add-ns').show();
-            });
+      $('.remove-ns').click(function(){
+        $(this).parents('tr')[0].remove();
+        $('input[name^=v_ns]').each(function(i, ns){
+          $(ns).attr({name: 'v_ns'+(i+1)});
+          i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+        })
+        $('.add-ns').show();
+      });
 
-            $('input[name^=v_ns]').each(function(i, ns){
-              i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-            });
-        });
-    </script>
-    <script src="/js/pages/add.package.js"></script>
+      $('input[name^=v_ns]').each(function(i, ns){
+        i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+      });
+    });
+  </script>
+  <script src="/js/pages/add.package.js"></script>

+ 17 - 17
web/templates/admin/add_user.js.html

@@ -1,18 +1,18 @@
-    <script>
-        $(function() {
-            $('#v_email').change(function() {
-                document.getElementById('v_notify').value = document.getElementById('v_email').value;
-            });
-        });
+  <script>
+    $(function() {
+      $('#v_email').change(function() {
+        document.getElementById('v_notify').value = document.getElementById('v_email').value;
+      });
+    });
 
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                randomstring += chars.substr(rnum, 1);
-            }
-            document.v_add_user.v_password.value = randomstring;
-        }
-    </script>
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_add_user.v_password.value = randomstring;
+    }
+  </script>

+ 40 - 40
web/templates/admin/add_web.js.html

@@ -1,45 +1,45 @@
-    <script>
-        $(function() {
-            $('#v_domain').change(function() {
-                var prefix = 'www.';
-                document.getElementById('v_aliases').value = prefix + document.getElementById('v_domain').value;
-            });
-        });
+  <script>
+    $(function() {
+      $('#v_domain').change(function() {
+        var prefix = 'www.';
+        document.getElementById('v_aliases').value = prefix + document.getElementById('v_domain').value;
+      });
+    });
 
-        function WEBrandom() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var webrandom = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                webrandom += chars.substr(rnum, 1);
-            }
-            document.v_add_web.v_stats_password.value = webrandom;
-        }
+    function WEBrandom() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var webrandom = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        webrandom += chars.substr(rnum, 1);
+      }
+      document.v_add_web.v_stats_password.value = webrandom;
+    }
 
-        function FTPrandom(elm) {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var ftprandomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                ftprandomstring += chars.substr(rnum, 1);
-            }
-            $(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
-        }
+    function FTPrandom(elm) {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var ftprandomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        ftprandomstring += chars.substr(rnum, 1);
+      }
+      $(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
+    }
 
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        $('#vstobjects').bind('submit', function(evt) {
-            $('input[disabled]').each(function(i, elm) {
-                $(elm).removeAttr('disabled');
-            });
-        });
+    $('#vstobjects').bind('submit', function(evt) {
+      $('input[disabled]').each(function(i, elm) {
+        $(elm).removeAttr('disabled');
+      });
+    });
 
-        GLOBAL.FTP_USER_PREFIX  = <?=json_encode($user)?>;
-        GLOBAL.FTP_USER_PREPATH = <?=json_encode($v_ftp_user_prepath)?>;
-    </script>
-    <script src="/js/pages/add.web.js"></script>
+    GLOBAL.FTP_USER_PREFIX  = <?=json_encode($user)?>;
+    GLOBAL.FTP_USER_PREPATH = <?=json_encode($v_ftp_user_prepath)?>;
+  </script>
+  <script src="/js/pages/add.web.js"></script>

+ 19 - 19
web/templates/admin/edit_db.js.html

@@ -1,21 +1,21 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                randomstring += chars.substr(rnum, 1);
-            }
-            document.v_edit_db.v_password.value = randomstring;
-        }
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_edit_db.v_password.value = randomstring;
+    }
 
-        GLOBAL.DB_USER_PREFIX = <?=json_encode($user.'_')?>;
-        GLOBAL.DB_DBNAME_PREFIX = <?=json_encode($user.'_')?>;
-    </script>
-    <script src="/js/pages/edit.db.js"></script>
+    GLOBAL.DB_USER_PREFIX = <?=json_encode($user.'_')?>;
+    GLOBAL.DB_DBNAME_PREFIX = <?=json_encode($user.'_')?>;
+  </script>
+  <script src="/js/pages/edit.db.js"></script>

+ 6 - 6
web/templates/admin/edit_firewall.js.html

@@ -1,6 +1,6 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
-    </script>
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
+  </script>

+ 6 - 6
web/templates/admin/edit_ip.js.html

@@ -1,6 +1,6 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
-    </script>
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
+  </script>

+ 17 - 17
web/templates/admin/edit_mail_acc.js.html

@@ -1,18 +1,18 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                randomstring += chars.substr(rnum, 1);
-            }
-            document.v_edit_mail_acc.v_password.value = randomstring;
-        }
-    </script>
-    <script src="/js/pages/edit.mail_acc.js"></script>
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_edit_mail_acc.v_password.value = randomstring;
+    }
+  </script>
+  <script src="/js/pages/edit.mail_acc.js"></script>

+ 28 - 28
web/templates/admin/edit_package.js.html

@@ -1,31 +1,31 @@
-    <script>
-          $(document).ready(function(){
-            $('.add-ns-button').click(function(){
-              var n = $("input[name^=v_ns]").length;
-              if(n < 8){
-                var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
-                t.find('input').attr({value:'', name:'v_ns'+(n+1)});
-                t.find('span').show();
-                $('tr.add-ns').before(t);
-              }
-              if( n == 7 ) {
-                $('.add-ns').hide();
-              }
-            });
+  <script>
+      $(document).ready(function(){
+      $('.add-ns-button').click(function(){
+        var n = $("input[name^=v_ns]").length;
+        if(n < 8){
+        var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
+        t.find('input').attr({value:'', name:'v_ns'+(n+1)});
+        t.find('span').show();
+        $('tr.add-ns').before(t);
+        }
+        if( n == 7 ) {
+        $('.add-ns').hide();
+        }
+      });
 
-            $('.remove-ns').click(function(){
-                $(this).parents('tr')[0].remove();
-                $('input[name^=v_ns]').each(function(i, ns){
-                    $(ns).attr({name: 'v_ns'+(i+1)});
-                    i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-                });
-                $('.add-ns').show();
-            });
+      $('.remove-ns').click(function(){
+        $(this).parents('tr')[0].remove();
+        $('input[name^=v_ns]').each(function(i, ns){
+          $(ns).attr({name: 'v_ns'+(i+1)});
+          i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+        });
+        $('.add-ns').show();
+      });
 
-            $('input[name^=v_ns]').each(function(i, ns){
-              i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-            });
+      $('input[name^=v_ns]').each(function(i, ns){
+        i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+      });
 
-        });
-    </script>
-    <script src="/js/pages/edit.package.js"></script>
+    });
+  </script>
+  <script src="/js/pages/edit.package.js"></script>

+ 22 - 22
web/templates/admin/edit_server.js.html

@@ -1,24 +1,24 @@
-    <script>
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+  <script>
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        $(document).ready(function(){
-            $('select[name=v_filemanager]').change(function(){
-                if($(this).val() == 'yes'){
-                    $('.filemanager.description').show();
-                } else {
-                    $('.filemanager.description').hide();
-                }
-            });
+    $(document).ready(function(){
+      $('select[name=v_filemanager]').change(function(){
+        if($(this).val() == 'yes'){
+          $('.filemanager.description').show();
+        } else {
+          $('.filemanager.description').hide();
+        }
+      });
 
-            $('select[name=v_sftp]').change(function(){
-                if($(this).val() == 'yes'){
-                    $('.sftp.description').show();
-                } else {
-                    $('.sftp.description').hide();
-                }
-            });
-         });
-    </script>
+      $('select[name=v_sftp]').change(function(){
+        if($(this).val() == 'yes'){
+          $('.sftp.description').show();
+        } else {
+          $('.sftp.description').hide();
+        }
+      });
+     });
+  </script>

+ 37 - 37
web/templates/admin/edit_user.js.html

@@ -1,41 +1,41 @@
-    <script>
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                randomstring += chars.substr(rnum, 1);
-            }
-            document.v_edit_user.v_password.value = randomstring;
-        }
+  <script>
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_edit_user.v_password.value = randomstring;
+    }
 
-        $(document).ready(function(){
-            $('.add-ns-button').click(function(){
-              var n = $("input[name^=v_ns]").length;
-              if(n < 8){
-                var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
-                t.find('input').attr({value:'', name:'v_ns'+(n+1)});
-                t.find('span').show();
-                $('tr.add-ns').before(t);
-              }
-              if( n == 7 ) {
-                $('.add-ns').hide();
-              }
-            });
+    $(document).ready(function(){
+      $('.add-ns-button').click(function(){
+        var n = $("input[name^=v_ns]").length;
+        if(n < 8){
+        var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
+        t.find('input').attr({value:'', name:'v_ns'+(n+1)});
+        t.find('span').show();
+        $('tr.add-ns').before(t);
+        }
+        if( n == 7 ) {
+        $('.add-ns').hide();
+        }
+      });
 
-            $('.remove-ns').click(function(){
-                $(this).parents('tr')[0].remove();
-                $('input[name^=v_ns]').each(function(i, ns){
-                    $(ns).attr({name: 'v_ns'+(i+1)});
-                    i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-                });
-                $('.add-ns').show();
-            });
+      $('.remove-ns').click(function(){
+        $(this).parents('tr')[0].remove();
+        $('input[name^=v_ns]').each(function(i, ns){
+          $(ns).attr({name: 'v_ns'+(i+1)});
+          i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+        });
+        $('.add-ns').show();
+      });
 
-            $('input[name^=v_ns]').each(function(i, ns){
-              i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-            });
+      $('input[name^=v_ns]').each(function(i, ns){
+        i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+      });
 
-        });
-    </script>
+    });
+  </script>

+ 37 - 37
web/templates/admin/edit_web.js.html

@@ -1,42 +1,42 @@
-    <script>
-        function WEBrandom() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var webrandom = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                webrandom += chars.substr(rnum, 1);
-            }
-            document.v_edit_web.v_stats_password.value = webrandom;
-        }
+  <script>
+    function WEBrandom() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var webrandom = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        webrandom += chars.substr(rnum, 1);
+      }
+      document.v_edit_web.v_stats_password.value = webrandom;
+    }
 
-        function FTPrandom(elm) {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var ftprandomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                ftprandomstring += chars.substr(rnum, 1);
-            }
+    function FTPrandom(elm) {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var ftprandomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        ftprandomstring += chars.substr(rnum, 1);
+      }
 
-            $(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
-            App.Actions.WEB.randomPasswordGenerated && App.Actions.WEB.randomPasswordGenerated(elm);
-        }
+      $(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
+      App.Actions.WEB.randomPasswordGenerated && App.Actions.WEB.randomPasswordGenerated(elm);
+    }
 
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        $('#vstobjects').bind('submit', function(evt) {
-            $('input[disabled]').each(function(i, elm) {
-                var copy_elm = $(elm).clone(true);
-                $(copy_elm).attr('type', 'hidden');
-                $(copy_elm).removeAttr('disabled');
-                $(elm).after(copy_elm);
-            });
-        });
+    $('#vstobjects').bind('submit', function(evt) {
+      $('input[disabled]').each(function(i, elm) {
+        var copy_elm = $(elm).clone(true);
+        $(copy_elm).attr('type', 'hidden');
+        $(copy_elm).removeAttr('disabled');
+        $(elm).after(copy_elm);
+      });
+    });
 
-        GLOBAL.FTP_USER_PREFIX = <?=json_encode($user.'_')?>;
-    </script>
-    <script src="/js/pages/edit.web.js"></script>
+    GLOBAL.FTP_USER_PREFIX = <?=json_encode($user.'_')?>;
+  </script>
+  <script src="/js/pages/edit.web.js"></script>

+ 69 - 69
web/templates/footer.html

@@ -1,84 +1,84 @@
-    </div>
-    <script type="text/javascript" src="/js/jquery-1.7.2.min.js?1446554103"></script>
-    <script type="text/javascript" src="/js/jquery.cookie.js?1446554103"></script>
-    <script type="text/javascript" src="/js/jquery-ui-1.8.20.custom.min.js?1467113876"></script>
-    <script type="text/javascript" src="/js/hotkeys.js?1446554103"></script>
-    <script type="text/javascript" src="/js/events.js?1446554103"></script>
-    <script type="text/javascript" src="/js/app.js?1446554103"></script>
-    <script type="text/javascript" src="/js/templates.js?1446554103"></script>
-    <script src="/js/jquery.finder.js"></script>
-    <script>
-      $(function() {
-        hover_menu();
-      });
-    </script>
+  </div>
+  <script type="text/javascript" src="/js/jquery-1.7.2.min.js?1446554103"></script>
+  <script type="text/javascript" src="/js/jquery.cookie.js?1446554103"></script>
+  <script type="text/javascript" src="/js/jquery-ui-1.8.20.custom.min.js?1467113876"></script>
+  <script type="text/javascript" src="/js/hotkeys.js?1446554103"></script>
+  <script type="text/javascript" src="/js/events.js?1446554103"></script>
+  <script type="text/javascript" src="/js/app.js?1446554103"></script>
+  <script type="text/javascript" src="/js/templates.js?1446554103"></script>
+  <script src="/js/jquery.finder.js"></script>
+  <script>
+    $(function() {
+      hover_menu();
+    });
+  </script>
 <?php
   @include($JS_FILE);
 ?>
 
 <?php
-  if (!empty($_SESSION['error_msg'])):
+if (!empty($_SESSION['error_msg'])):
 ?>
-    <div>
-      <div id="dialog-message" title="">
-        <p><?=htmlentities($_SESSION['error_msg'])?></p>
-      </div>
-      <script>
-        $('#dialog:ui-dialog').dialog('destroy');
-        $('#dialog-message').dialog({
-          modal: true,
-          buttons: {
-            Ok: function() {
-              $(this).dialog('close');
-            }
-          },
-          create: function() {
-            $(this)
-            .closest('.ui-dialog')
-            .find('.ui-button:first')
-            .addClass('submit');
-          }
-        });
-      </script>
+  <div>
+    <div id="dialog-message" title="">
+      <p><?=htmlentities($_SESSION['error_msg'])?></p>
     </div>
+    <script>
+      $('#dialog:ui-dialog').dialog('destroy');
+      $('#dialog-message').dialog({
+        modal: true,
+        buttons: {
+          Ok: function() {
+            $(this).dialog('close');
+          }
+        },
+        create: function() {
+          $(this)
+          .closest('.ui-dialog')
+          .find('.ui-button:first')
+          .addClass('submit');
+        }
+      });
+    </script>
+  </div>
 <?php
-    unset($_SESSION['error_msg']);
-  endif;
+  unset($_SESSION['error_msg']);
+endif;
 ?>
 
-    <div title="Confirmation" class="confirmation-text-redirect hidden">
-      <p class="confirmation"><?=__('LEAVE_PAGE_CONFIRMATION')?></p>
-    </div>
+  <div title="Confirmation" class="confirmation-text-redirect hidden">
+    <p class="confirmation"><?=__('LEAVE_PAGE_CONFIRMATION')?></p>
+  </div>
 
-    <div class="shortcuts" style="display:none">
-      <div class="header">
-        <div class="title">Shortcuts</div>
-        <div class="close"></div>
-      </div>
-      <ul>
-        <li><span class="key">a</span><?=__('Add New object')?></li>
-        <li><span class="key">Ctrl + Enter</span><?=__('Save Form')?></li>
-        <li><span class="key">Ctrl + Backspace</span><?=__('Cancel saving form')?></li>
+  <div class="shortcuts" style="display:none">
+    <div class="header">
+      <div class="title">Shortcuts</div>
+      <div class="close"></div>
+    </div>
+    <ul>
+      <li><span class="key">a</span><?=__('Add New object')?></li>
+      <li><span class="key">Ctrl + Enter</span><?=__('Save Form')?></li>
+      <li><span class="key">Ctrl + Backspace</span><?=__('Cancel saving form')?></li>
 
-        <li class="step-top"><span class="key">1</span><?=__('Go to USER list')?></li>
-        <li><span class="key">2</span><?=__('Go to WEB list')?></li>
-        <li><span class="key">3</span><?=__('Go to DNS list')?></li>
-        <li><span class="key">4</span><?=__('Go to MAIL list')?></li>
-        <li><span class="key">5</span><?=__('Go to DB list')?></li>
-        <li><span class="key">6</span><?=__('Go to CRON list')?></li>
-        <li><span class="key">7</span><?=__('Go to BACKUP list')?></li>
-      </ul>
-      <ul>
-        <li><span class="key">f</span><?=__('Focus on search')?></li>
-        <li class="step-top"><span class="key">h</span><?=__('Display/Close shortcuts')?></li>
+      <li class="step-top"><span class="key">1</span><?=__('Go to USER list')?></li>
+      <li><span class="key">2</span><?=__('Go to WEB list')?></li>
+      <li><span class="key">3</span><?=__('Go to DNS list')?></li>
+      <li><span class="key">4</span><?=__('Go to MAIL list')?></li>
+      <li><span class="key">5</span><?=__('Go to DB list')?></li>
+      <li><span class="key">6</span><?=__('Go to CRON list')?></li>
+      <li><span class="key">7</span><?=__('Go to BACKUP list')?></li>
+    </ul>
+    <ul>
+      <li><span class="key">f</span><?=__('Focus on search')?></li>
+      <li class="step-top"><span class="key">h</span><?=__('Display/Close shortcuts')?></li>
 
-        <li class="step-top"><span class="key bigger">&larr;</span><?=__('Move backward through top menu')?></li>
-        <li><span class="key bigger">&rarr;</span><?=__('Move forward through top menu')?></li>
-        <li><span class="key">Enter</span><?=__('Enter focused element')?></li>
+      <li class="step-top"><span class="key bigger">&larr;</span><?=__('Move backward through top menu')?></li>
+      <li><span class="key bigger">&rarr;</span><?=__('Move forward through top menu')?></li>
+      <li><span class="key">Enter</span><?=__('Enter focused element')?></li>
 
-        <li class="step-top"><span class="key bigger">&uarr;</span><?=__('Move up through elements list')?></li>
-        <li><span class="key bigger">&darr;</span><?=__('Move down through elements list')?></li>
-      </ul>
-    </div>
-    </body>
+      <li class="step-top"><span class="key bigger">&uarr;</span><?=__('Move up through elements list')?></li>
+      <li><span class="key bigger">&darr;</span><?=__('Move down through elements list')?></li>
+    </ul>
+  </div>
+</body>
 </html>

+ 37 - 37
web/templates/user/edit_user.js.html

@@ -1,41 +1,41 @@
-    <script>
-        function randomString() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var randomstring = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                randomstring += chars.substr(rnum, 1);
-            }
-            document.v_edit_user.v_password.value = randomstring;
-        }
+  <script>
+    function randomString() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var randomstring = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        randomstring += chars.substr(rnum, 1);
+      }
+      document.v_edit_user.v_password.value = randomstring;
+    }
 
-        $(document).ready(function(){
-            $('.add-ns-button').click(function(){
-              var n = $("input[name^=v_ns]").length;
-              if(n < 8){
-                var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
-                t.find('input').attr({value:'', name:'v_ns'+(n+1)});
-                t.find('span').show();
-                $('tr.add-ns').before(t);
-              }
-              if( n == 7 ) {
-                $('.add-ns').hide();
-              }
-            });
+    $(document).ready(function(){
+      $('.add-ns-button').click(function(){
+        var n = $("input[name^=v_ns]").length;
+        if(n < 8){
+        var t = $($('input[name=v_ns1]').parents('tr')[0]).clone(true, true);
+        t.find('input').attr({value:'', name:'v_ns'+(n+1)});
+        t.find('span').show();
+        $('tr.add-ns').before(t);
+        }
+        if( n == 7 ) {
+        $('.add-ns').hide();
+        }
+      });
 
-            $('.remove-ns').click(function(){
-                $(this).parents('tr')[0].remove();
-                $('input[name^=v_ns]').each(function(i, ns){
-                    $(ns).attr({name: 'v_ns'+(i+1)});
-                    i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-                });
-                $('.add-ns').show();
-            });
+      $('.remove-ns').click(function(){
+        $(this).parents('tr')[0].remove();
+        $('input[name^=v_ns]').each(function(i, ns){
+          $(ns).attr({name: 'v_ns'+(i+1)});
+          i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+        });
+        $('.add-ns').show();
+      });
 
-            $('input[name^=v_ns]').each(function(i, ns){
-              i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
-            });
+      $('input[name^=v_ns]').each(function(i, ns){
+        i < 2 ? $(ns).parent().find('span').hide() : $(ns).parent().find('span').show();
+      });
 
-        });
-    </script>
+    });
+  </script>

+ 37 - 37
web/templates/user/edit_web.js.html

@@ -1,42 +1,42 @@
-    <script>
-        function WEBrandom() {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var webrandom = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                webrandom += chars.substr(rnum, 1);
-            }
-            document.v_edit_web.v_stats_password.value = webrandom;
-        }
+  <script>
+    function WEBrandom() {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var webrandom = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        webrandom += chars.substr(rnum, 1);
+      }
+      document.v_edit_web.v_stats_password.value = webrandom;
+    }
 
-        function FTPrandom(elm) {
-            var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
-            var string_length = 10;
-            var webrandom = '';
-            for (var i = 0; i < string_length; i++) {
-                var rnum = Math.floor(Math.random() * chars.length);
-                webrandom += chars.substr(rnum, 1);
-            }
+    function FTPrandom(elm) {
+      var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz';
+      var string_length = 10;
+      var webrandom = '';
+      for (var i = 0; i < string_length; i++) {
+        var rnum = Math.floor(Math.random() * chars.length);
+        webrandom += chars.substr(rnum, 1);
+      }
 
-            $(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
-            App.Actions.WEB.randomPasswordGenerated && App.Actions.WEB.randomPasswordGenerated(elm);
-        }
+      $(elm).parents('.ftptable').find('.v-ftp-user-psw').val(ftprandomstring);
+      App.Actions.WEB.randomPasswordGenerated && App.Actions.WEB.randomPasswordGenerated(elm);
+    }
 
-        function elementHideShow(elementToHideOrShow){
-            var el = document.getElementById(elementToHideOrShow);
-            el.style.display = el.style.display === 'none' ? 'block' : 'none';
-        }
+    function elementHideShow(elementToHideOrShow){
+      var el = document.getElementById(elementToHideOrShow);
+      el.style.display = el.style.display === 'none' ? 'block' : 'none';
+    }
 
-        $('#vstobjects').bind('submit', function(evt) {
-            $('input[disabled]').each(function(i, elm) {
-                var copy_elm = $(elm).clone(true);
-                $(copy_elm).attr('type', 'hidden');
-                $(copy_elm).removeAttr('disabled');
-                $(elm).after(copy_elm);
-            });
-        });
+    $('#vstobjects').bind('submit', function(evt) {
+      $('input[disabled]').each(function(i, elm) {
+        var copy_elm = $(elm).clone(true);
+        $(copy_elm).attr('type', 'hidden');
+        $(copy_elm).removeAttr('disabled');
+        $(elm).after(copy_elm);
+      });
+    });
 
-        GLOBAL.FTP_USER_PREFIX = <?=json_encode($user.'_')?>;
-    </script>
-    <script src="/js/pages/edit.web.js"></script>
+    GLOBAL.FTP_USER_PREFIX = <?=json_encode($user.'_')?>;
+  </script>
+  <script src="/js/pages/edit.web.js"></script>