diff --git a/web/js/app.js b/web/js/app.js index ea14621581..7bd5bc70f4 100644 --- a/web/js/app.js +++ b/web/js/app.js @@ -63,7 +63,6 @@ $.fn.scrollTo = function( target, options, callback ){ * The mask defaults to dateFormat.masks.default. */ - var dateFormat = function () { var token = /d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZ]|"[^"]*"|'[^']*'/g, timezone = /\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g, diff --git a/web/js/pages/add_db.js b/web/js/pages/add_db.js index 82b757e6a6..0660c0473c 100644 --- a/web/js/pages/add_db.js +++ b/web/js/pages/add_db.js @@ -3,7 +3,7 @@ // Updates database username dynamically, showing its prefix App.Actions.DB.update_db_username_hint = function(elm, hint) { if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } $(elm).parent().find('.hint').text(GLOBAL.DB_USER_PREFIX + hint); } @@ -13,7 +13,7 @@ App.Actions.DB.update_db_username_hint = function(elm, hint) { // Updates database name dynamically, showing its prefix App.Actions.DB.update_db_databasename_hint = function(elm, hint) { if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } $(elm).parent().find('.hint').text(GLOBAL.DB_DBNAME_PREFIX + hint); } diff --git a/web/js/pages/add_dns_rec.js b/web/js/pages/add_dns_rec.js index 06c3649e5f..a6ebb04623 100644 --- a/web/js/pages/add_dns_rec.js +++ b/web/js/pages/add_dns_rec.js @@ -4,7 +4,7 @@ App.Actions.DB.update_dns_record_hint = function(elm, hint) { // clean hint if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } // set domain name without rec in case of @ entries diff --git a/web/js/pages/add_mail_acc.js b/web/js/pages/add_mail_acc.js index 153f099eb9..28fe256c2b 100644 --- a/web/js/pages/add_mail_acc.js +++ b/web/js/pages/add_mail_acc.js @@ -141,7 +141,7 @@ generate_mail_credentials = function() { var div = $('.mail-infoblock').clone(); div.find('#mail_configuration').remove(); var pass=div.find('#v_password').text(); - if (pass=="") div.find('#v_password').html(' '); + if (pass=="") div.find('#v_password').text(' '); var output = div.text(); output=output.replace(/(?:\r\n|\r|\n|\t)/g, "|"); output=output.replace(/ /g, ""); @@ -188,29 +188,29 @@ $(document).ready(function() { switch(opt.attr('v_type')){ case 'hostname': - $('#td_imap_hostname').html(opt.attr('domain')); - $('#td_smtp_hostname').html(opt.attr('domain')); + $('#td_imap_hostname').text(opt.attr('domain')); + $('#td_smtp_hostname').text(opt.attr('domain')); break; case 'starttls': - $('#td_imap_port').html('143'); - $('#td_imap_encryption').html('STARTTLS'); - $('#td_smtp_port').html('587'); - $('#td_smtp_encryption').html('STARTTLS'); + $('#td_imap_port').text('143'); + $('#td_imap_encryption').text('STARTTLS'); + $('#td_smtp_port').text('587'); + $('#td_smtp_encryption').text('STARTTLS'); break; case 'ssl': - $('#td_imap_port').html('993'); - $('#td_imap_encryption').html('SSL / TLS'); - $('#td_smtp_port').html('465'); - $('#td_smtp_encryption').html('SSL / TLS'); + $('#td_imap_port').text('993'); + $('#td_imap_encryption').text('SSL / TLS'); + $('#td_smtp_port').text('465'); + $('#td_smtp_encryption').text('SSL / TLS'); break; case 'no_encryption': - $('#td_imap_hostname').html(opt.attr('domain')); - $('#td_smtp_hostname').html(opt.attr('domain')); + $('#td_imap_hostname').text(opt.attr('domain')); + $('#td_smtp_hostname').text(opt.attr('domain')); - $('#td_imap_port').html('143'); - $('#td_imap_encryption').html(opt.attr('no_encryption')); - $('#td_smtp_port').html('25'); - $('#td_smtp_encryption').html(opt.attr('no_encryption')); + $('#td_imap_port').text('143'); + $('#td_imap_encryption').text(opt.attr('no_encryption')); + $('#td_smtp_port').text('25'); + $('#td_smtp_encryption').text(opt.attr('no_encryption')); break; } generate_mail_credentials(); diff --git a/web/js/pages/add_web.js b/web/js/pages/add_web.js index 87daf45648..5118d1c338 100644 --- a/web/js/pages/add_web.js +++ b/web/js/pages/add_web.js @@ -3,7 +3,7 @@ var domain = $('select[name="v-custom-doc-domain"]').val(); var folder = $('input[name="v-custom-doc-folder"]').val(); console.log(domain, folder); - $('.custom_docroot_hint').html(prepath+domain+'/public_html/'+folder); + $('.custom_docroot_hint').text(prepath+domain+'/public_html/'+folder); } App.Listeners.DB.keypress_custom_folder = function() { var ref = $('input[name="v-custom-doc-folder"]'); @@ -40,7 +40,7 @@ App.Listeners.DB.change_custom_doc(); App.Actions.WEB.update_ftp_username_hint = function(elm, hint) { if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } hint = hint.replace(/[^\w\d]/gi, ''); @@ -88,7 +88,7 @@ App.Listeners.WEB.keypress_domain_name = function() { App.Actions.WEB.update_ftp_path_hint = function(elm, hint) { if (hint.trim() == '') { - $(elm).parent().find('.v-ftp-path-hint').html(''); + $(elm).parent().find('.v-ftp-path-hint').text(''); } if (hint[0] != '/') { diff --git a/web/js/pages/edit_db.js b/web/js/pages/edit_db.js index 9a8a514ee1..a82ed4e8c3 100644 --- a/web/js/pages/edit_db.js +++ b/web/js/pages/edit_db.js @@ -3,7 +3,7 @@ // Updates database username dynamically, showing its prefix App.Actions.DB.update_db_username_hint = function(elm, hint) { if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } $(elm).parent().find('.hint').text(GLOBAL.DB_USER_PREFIX + hint); } @@ -13,7 +13,7 @@ App.Actions.DB.update_db_username_hint = function(elm, hint) { // Updates database name dynamically, showing its prefix App.Actions.DB.update_db_databasename_hint = function(elm, hint) { if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } $(elm).parent().find('.hint').text(GLOBAL.DB_DBNAME_PREFIX + hint); } diff --git a/web/js/pages/edit_dns_rec.js b/web/js/pages/edit_dns_rec.js index 06c3649e5f..a6ebb04623 100644 --- a/web/js/pages/edit_dns_rec.js +++ b/web/js/pages/edit_dns_rec.js @@ -4,7 +4,7 @@ App.Actions.DB.update_dns_record_hint = function(elm, hint) { // clean hint if (hint.trim() == '') { - $(elm).parent().find('.hint').html(''); + $(elm).parent().find('.hint').text(''); } // set domain name without rec in case of @ entries diff --git a/web/js/pages/edit_mail_acc.js b/web/js/pages/edit_mail_acc.js index 3ff42ce74c..06b37764f8 100644 --- a/web/js/pages/edit_mail_acc.js +++ b/web/js/pages/edit_mail_acc.js @@ -119,7 +119,7 @@ generate_mail_credentials = function() { var div = $('.mail-infoblock').clone(); div.find('#mail_configuration').remove(); var pass=div.find('#v_password').text(); - if (pass=="") div.find('#v_password').html(' '); + if (pass=="") div.find('#v_password').text(' '); var output = div.text(); output=output.replace(/(?:\r\n|\r|\n|\t)/g, "|"); output=output.replace(/ /g, ""); @@ -166,29 +166,29 @@ $(document).ready(function() { switch(opt.attr('v_type')){ case 'hostname': - $('#td_imap_hostname').html(opt.attr('domain')); - $('#td_smtp_hostname').html(opt.attr('domain')); + $('#td_imap_hostname').text(opt.attr('domain')); + $('#td_smtp_hostname').text(opt.attr('domain')); break; case 'starttls': - $('#td_imap_port').html('143'); - $('#td_imap_encryption').html('STARTTLS'); - $('#td_smtp_port').html('587'); - $('#td_smtp_encryption').html('STARTTLS'); + $('#td_imap_port').text('143'); + $('#td_imap_encryption').text('STARTTLS'); + $('#td_smtp_port').text('587'); + $('#td_smtp_encryption').text('STARTTLS'); break; case 'ssl': - $('#td_imap_port').html('993'); - $('#td_imap_encryption').html('SSL / TLS'); - $('#td_smtp_port').html('465'); - $('#td_smtp_encryption').html('SSL / TLS'); + $('#td_imap_port').text('993'); + $('#td_imap_encryption').text('SSL / TLS'); + $('#td_smtp_port').text('465'); + $('#td_smtp_encryption').text('SSL / TLS'); break; case 'no_encryption': - $('#td_imap_hostname').html(opt.attr('domain')); - $('#td_smtp_hostname').html(opt.attr('domain')); + $('#td_imap_hostname').text(opt.attr('domain')); + $('#td_smtp_hostname').text(opt.attr('domain')); - $('#td_imap_port').html('143'); - $('#td_imap_encryption').html(opt.attr('no_encryption')); - $('#td_smtp_port').html('25'); - $('#td_smtp_encryption').html(opt.attr('no_encryption')); + $('#td_imap_port').text('143'); + $('#td_imap_encryption').text(opt.attr('no_encryption')); + $('#td_smtp_port').text('25'); + $('#td_smtp_encryption').text(opt.attr('no_encryption')); break; } generate_mail_credentials(); diff --git a/web/templates/pages/add_db.html b/web/templates/pages/add_db.html index aa283c46b4..75831dfba9 100644 --- a/web/templates/pages/add_db.html +++ b/web/templates/pages/add_db.html @@ -61,7 +61,7 @@ - '.$user.'_'); ?> + '.$user_plain.'_'); ?> @@ -227,6 +227,6 @@ \ No newline at end of file diff --git a/web/templates/pages/edit_db.html b/web/templates/pages/edit_db.html index 6cff3f6a70..f4f570892b 100644 --- a/web/templates/pages/edit_db.html +++ b/web/templates/pages/edit_db.html @@ -126,6 +126,6 @@ \ No newline at end of file