Update to Bootstrap v4.3.1, jQuery 3.4.1. Adjustments to support updates.
This commit is contained in:
@@ -437,7 +437,7 @@
|
||||
elseif ($category == "theme" && substr_count($subcategory, "_font") > 0 && $name == "text") {
|
||||
$default_setting_value = str_replace('"', "'", $default_setting_value);
|
||||
if ($fonts = get_available_fonts('alpha')) {
|
||||
echo " <select class='formfld' id='sel_default_setting_value' onchange=\"if (this.selectedIndex == $('select#sel_default_setting_value option').length - 1) { $('#txt_default_setting_value').val('').fadeIn('fast'); $('#txt_default_setting_value').focus(); } else { $('#txt_default_setting_value').fadeOut('fast', function(){ $('#txt_default_setting_value').val($('#sel_default_setting_value').val()) }); } \">\n";
|
||||
echo " <select class='formfld' id='sel_default_setting_value' onchange=\"if (this.selectedIndex == $('select#sel_default_setting_value option').length - 1) { $('#txt_default_setting_value').val('').fadeIn('fast'); $('#txt_default_setting_value').trigger('focus'); } else { $('#txt_default_setting_value').fadeOut('fast', function(){ $('#txt_default_setting_value').val($('#sel_default_setting_value').val()) }); } \">\n";
|
||||
echo " <option value=''></option>\n";
|
||||
echo " <optgroup label='".$text['label-web_fonts']."'>\n";
|
||||
$option_found = false;
|
||||
@@ -671,7 +671,7 @@
|
||||
echo "<script>\n";
|
||||
//capture enter key to submit form
|
||||
if (!($category == "theme" && $subcategory == "custom_css_code" && $name == "text" )) {
|
||||
echo " $(window).keypress(function(event){\n";
|
||||
echo " $(window).on('keypress',function(event){\n";
|
||||
echo " if (event.which == 13) { submit_form(); }\n";
|
||||
echo " });\n";
|
||||
}
|
||||
@@ -682,9 +682,9 @@
|
||||
echo " $('form#frm').submit();\n";
|
||||
echo " }\n";
|
||||
//define lowercase class
|
||||
echo " $('.lowercase').blur(function(){ this.value = this.value.toLowerCase(); });";
|
||||
echo " $('.lowercase').on('blur',function(){ this.value = this.value.toLowerCase(); });";
|
||||
//show order if array
|
||||
echo " $('#default_setting_name').keyup(function(){ \n";
|
||||
echo " $('#default_setting_name').on('keyup',function(){ \n";
|
||||
echo " (this.value.toLowerCase() == 'array') ? $('#tr_order').slideDown('fast') : $('#tr_order').slideUp('fast');\n";
|
||||
echo " });\n";
|
||||
echo "</script>\n";
|
||||
|
||||
@@ -219,7 +219,7 @@
|
||||
echo " }\n";
|
||||
echo "\n";
|
||||
echo " $( document ).ready(function() {\n";
|
||||
echo " $('#default_setting_search').focus();\n";
|
||||
echo " $('#default_setting_search').trigger('focus').trigger('select');\n";
|
||||
if ($search == '') {
|
||||
echo " // scroll to previous category\n";
|
||||
echo " var category_span_id;\n";
|
||||
@@ -240,7 +240,7 @@
|
||||
//prevent enter key submit on search field
|
||||
echo "<script language='javascript' type='text/javascript'>\n";
|
||||
echo " $(document).ready(function() {\n";
|
||||
echo " $('#default_setting_search').keydown(function(event){\n";
|
||||
echo " $('#default_setting_search').on('keydown',function(event){\n";
|
||||
echo " if (event.keyCode == 13) {\n";
|
||||
echo " event.preventDefault();\n";
|
||||
echo " return false;\n";
|
||||
@@ -533,7 +533,6 @@
|
||||
//auto run, if search term passed back
|
||||
if ($search != '') {
|
||||
echo " setting_search();";
|
||||
echo " $('#default_setting_search').select();\n";
|
||||
}
|
||||
echo "</script>\n";
|
||||
|
||||
|
||||
@@ -421,6 +421,26 @@ $text['label-fixed']['ru-ru'] = "Фиксированный";
|
||||
$text['label-fixed']['sv-se'] = "Fast";
|
||||
$text['label-fixed']['uk-ua'] = "фіксований";
|
||||
|
||||
$text['label-side']['en-us'] = "Side";
|
||||
$text['label-side']['ar-eg'] = "Side";
|
||||
$text['label-side']['de-at'] = "Side";
|
||||
$text['label-side']['de-ch'] = "Side";
|
||||
$text['label-side']['de-de'] = "Side";
|
||||
$text['label-side']['es-cl'] = "Side";
|
||||
$text['label-side']['es-mx'] = "Side";
|
||||
$text['label-side']['fr-ca'] = "Side";
|
||||
$text['label-side']['fr-fr'] = "Side";
|
||||
$text['label-side']['he-il'] = "Side";
|
||||
$text['label-side']['it-it'] = "Side";
|
||||
$text['label-side']['nl-nl'] = "Side";
|
||||
$text['label-side']['pl-pl'] = "Side";
|
||||
$text['label-side']['pt-br'] = "Side";
|
||||
$text['label-side']['pt-pt'] = "Side";
|
||||
$text['label-side']['ro-ro'] = "Side";
|
||||
$text['label-side']['ru-ru'] = "Side";
|
||||
$text['label-side']['sv-se'] = "Side";
|
||||
$text['label-side']['uk-ua'] = "Side";
|
||||
|
||||
$text['label-domain']['en-us'] = "Domain";
|
||||
$text['label-domain']['ar-eg'] = "";
|
||||
$text['label-domain']['de-at'] = "Domain"; //copied from de-de
|
||||
|
||||
@@ -382,7 +382,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo " <input type='text' class='formfld' name='domain_setting_category' id='domain_setting_category' maxlength='255' value=\"".escape($domain_setting_category)."\">\n";
|
||||
}
|
||||
else {
|
||||
echo " <select class='formfld' name='domain_setting_category' id='domain_setting_category' onchange=\"$('#domain_setting_subcategory').focus();\">\n";
|
||||
echo " <select class='formfld' name='domain_setting_category' id='domain_setting_category' onchange=\"$('#domain_setting_subcategory').trigger('focus');\">\n";
|
||||
echo " <option value=''></option>\n";
|
||||
if (is_array($allowed_categories) && sizeof($allowed_categories) > 0) {
|
||||
foreach ($allowed_categories as $category) {
|
||||
@@ -534,7 +534,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
elseif ($category == "theme" && substr_count($subcategory, "_font") > 0 && $name == "text") {
|
||||
$row['domain_setting_value'] = str_replace('"', "'", $row['domain_setting_value']);
|
||||
if ($fonts = get_available_fonts('alpha')) {
|
||||
echo " <select class='formfld' id='sel_domain_setting_value' onchange=\"if (this.selectedIndex == $('select#sel_domain_setting_value option').length - 1) { $('#txt_domain_setting_value').val('').fadeIn('fast'); $('#txt_domain_setting_value').focus(); } else { $('#txt_domain_setting_value').fadeOut('fast', function(){ $('#txt_domain_setting_value').val($('#sel_domain_setting_value').val()) }); } \">\n";
|
||||
echo " <select class='formfld' id='sel_domain_setting_value' onchange=\"if (this.selectedIndex == $('select#sel_domain_setting_value option').length - 1) { $('#txt_domain_setting_value').val('').fadeIn('fast'); $('#txt_domain_setting_value').trigger('focus'); } else { $('#txt_domain_setting_value').fadeOut('fast', function(){ $('#txt_domain_setting_value').val($('#sel_domain_setting_value').val()) }); } \">\n";
|
||||
echo " <option value=''></option>\n";
|
||||
echo " <optgroup label='".$text['label-web_fonts']."'>\n";
|
||||
$option_found = false;
|
||||
@@ -623,6 +623,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo " <option value='fixed' ".(($row['domain_setting_value'] == "fixed") ? "selected='selected'" : null).">".$text['label-fixed']."</option>\n";
|
||||
echo " <option value='static' ".(($row['domain_setting_value'] == "static") ? "selected='selected'" : null).">".$text['label-static']."</option>\n";
|
||||
echo " <option value='inline' ".(($row['domain_setting_value'] == "inline") ? "selected='selected'" : null).">".$text['label-inline']."</option>\n";
|
||||
echo " <option value='side' ".(($row['domain_setting_value'] == "side") ? "selected='selected'" : null).">".$text['label-side']."</option>\n";
|
||||
echo " </select>\n";
|
||||
}
|
||||
elseif ($category == "theme" && $subcategory == "menu_position" && $name == "text" ) {
|
||||
@@ -732,7 +733,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
|
||||
echo "<script>\n";
|
||||
//capture enter key to submit form
|
||||
echo " $(window).keypress(function(event){\n";
|
||||
echo " $(window).on('keypress',function(event){\n";
|
||||
echo " if (event.which == 13) { submit_form(); }\n";
|
||||
echo " });\n";
|
||||
//hide/convert password fields then submit form
|
||||
@@ -742,9 +743,9 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo " $('form#frm').submit();\n";
|
||||
echo " }\n";
|
||||
//define lowercase class
|
||||
echo " $('.lowercase').blur(function(){ this.value = this.value.toLowerCase(); });";
|
||||
echo " $('.lowercase').on('blur',function(){ this.value = this.value.toLowerCase(); });";
|
||||
//show order if array
|
||||
echo " $('#domain_setting_name').keyup(function(){ \n";
|
||||
echo " $('#domain_setting_name').on('keyup',function(){ \n";
|
||||
echo " (this.value.toLowerCase() == 'array') ? $('#tr_order').slideDown('fast') : $('#tr_order').slideUp('fast');\n";
|
||||
echo " });\n";
|
||||
echo "</script>\n";
|
||||
|
||||
@@ -514,8 +514,8 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo " });\n";
|
||||
echo " }\n";
|
||||
echo "\n";
|
||||
echo " $( document ).ready(function() {\n";
|
||||
echo " $('#domain_setting_search').focus();\n";
|
||||
echo " $(document).ready(function() {\n";
|
||||
echo " $('#domain_setting_search').trigger('focus');\n";
|
||||
if ($search == '') {
|
||||
echo " // scroll to previous category\n";
|
||||
echo " var category_span_id;\n";
|
||||
|
||||
@@ -339,7 +339,7 @@
|
||||
echo " }\n";
|
||||
echo "\n";
|
||||
echo " $( document ).ready(function() {\n";
|
||||
echo " $('#group_permission_search').focus();\n";
|
||||
echo " $('#group_permission_search').trigger('focus');\n";
|
||||
echo " });\n";
|
||||
echo "</script>\n";
|
||||
|
||||
|
||||
@@ -400,36 +400,36 @@ else {
|
||||
echo " <tr>";
|
||||
echo " <td class='vncell'>".$text['label-icon']."</td>";
|
||||
echo " <td class='vtable' style='vertical-align: bottom;'>";
|
||||
if (file_exists($_SERVER["PROJECT_ROOT"].'/resources/bootstrap/glyphicons.json')) {
|
||||
$tmp_array = json_decode(file_get_contents($_SERVER["PROJECT_ROOT"].'/resources/bootstrap/glyphicons.json'), true);
|
||||
if (is_array($tmp_array['icons']) && sizeof($tmp_array['icons']) > 0) {
|
||||
if (file_exists($_SERVER["PROJECT_ROOT"].'/resources/fontawesome/fas_icons.php')) {
|
||||
include 'resources/fontawesome/fas_icons.php';
|
||||
if (is_array($font_awesome_solid_icons) && @sizeof($font_awesome_solid_icons) != 0) {
|
||||
// rebuild and sort array
|
||||
foreach ($tmp_array['icons'] as $i => $glyphicon) {
|
||||
$tmp_string = str_replace('glyphicon-', '', $glyphicon['id']);
|
||||
$tmp_string = str_replace('-', ' ', $tmp_string);
|
||||
$tmp_string = ucwords($tmp_string);
|
||||
$glyphicons[$glyphicon['id']] = $tmp_string;
|
||||
foreach ($font_awesome_solid_icons as $i => $icon_class) {
|
||||
$icon_label = str_replace('fa-', '', $icon_class);
|
||||
$icon_label = str_replace('-', ' ', $icon_label);
|
||||
$icon_label = ucwords($icon_label);
|
||||
$icons[$icon_class] = $icon_label;
|
||||
}
|
||||
asort($glyphicons, SORT_STRING);
|
||||
asort($icons, SORT_STRING);
|
||||
echo "<table cellpadding='0' cellspacing='0' border='0'>\n";
|
||||
echo " <tr>\n";
|
||||
echo " <td>\n";
|
||||
echo " <select class='formfld' name='menu_item_icon' id='menu_item_icon' onchange=\"$('#glyphicons').slideUp(); $('#grid_icon').fadeIn();\">\n";
|
||||
echo " <select class='formfld' name='menu_item_icon' id='menu_item_icon' onchange=\"$('#icons').slideUp(); $('#grid_icon').fadeIn();\">\n";
|
||||
echo " <option value=''></option>\n";
|
||||
foreach ($glyphicons as $glyphicon_class => $glyphicon_name) {
|
||||
$selected = ($menu_item_icon == $glyphicon_class) ? "selected" : null;
|
||||
echo " <option value='".escape($glyphicon_class)."' ".$selected.">".escape($glyphicon_name)."</option>\n";
|
||||
foreach ($icons as $icon_class => $icon_label) {
|
||||
$selected = ($menu_item_icon == $icon_class) ? "selected" : null;
|
||||
echo " <option value='".escape($icon_class)."' ".$selected.">".escape($icon_label)."</option>\n";
|
||||
}
|
||||
echo " </select>\n";
|
||||
echo " </td>\n";
|
||||
echo " <td style='padding: 0 0 0 5px;'>\n";
|
||||
echo " <button id='grid_icon' type='button' class='btn btn-default list_control_icon' style='font-size: 15px; padding-top: 1px; padding-left: 3px;' onclick=\"$('#glyphicons').slideToggle(); $(this).fadeOut();\"><span class='glyphicon glyphicon-th'></span></button>";
|
||||
echo " <button id='grid_icon' type='button' class='btn btn-default list_control_icon' style='font-size: 15px; padding-top: 1px; padding-left: 3px;' onclick=\"$('#icons').fadeIn(); $(this).fadeOut();\"><span class='fas fa-th'></span></button>";
|
||||
echo " </td>\n";
|
||||
echo " </tr>\n";
|
||||
echo "</table>\n";
|
||||
echo "<div id='glyphicons' style='clear: both; display: none; padding-top: 10px; color: #000;'>";
|
||||
foreach ($glyphicons as $glyphicon_class => $glyphicon_name) {
|
||||
echo "<span class='glyphicon ".escape($glyphicon_class)."' style='font-size: 24px; float: left; margin: 0 8px 8px 0; cursor: pointer; opacity: 0.3;' title='".escape(glyphicon_name)."' onclick=\"$('#menu_item_icon').val('".escape($glyphicon_class)."'); $('#glyphicons').slideUp(); $('#grid_icon').fadeIn();\" onmouseover=\"this.style.opacity='1';\" onmouseout=\"this.style.opacity='0.3';\"></span>\n";
|
||||
echo "<div id='icons' style='clear: both; display: none; margin-top: 8px; padding-top: 10px; color: #000; max-height: 400px; overflow: auto;'>\n";
|
||||
foreach ($icons as $icon_class => $icon_label) {
|
||||
echo "<span class='fas ".escape($icon_class)." fa-fw' style='font-size: 24px; float: left; margin: 0 8px 8px 0; cursor: pointer; opacity: 0.3;' title='".escape($icon_label)."' onclick=\"$('#menu_item_icon').val('".escape($icon_class)."'); $('#icons').slideUp(); $('#grid_icon').fadeIn();\" onmouseover=\"this.style.opacity='1';\" onmouseout=\"this.style.opacity='0.3';\"></span>\n";
|
||||
}
|
||||
echo "</div>";
|
||||
}
|
||||
|
||||
@@ -377,7 +377,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo " <input type='text' class='formfld' name='user_setting_category' id='user_setting_category' maxlength='255' value=\"".escape($user_setting_category)."\">\n";
|
||||
}
|
||||
else {
|
||||
echo " <select class='formfld' name='user_setting_category' id='user_setting_category' onchange=\"$('#user_setting_subcategory').focus();\">\n";
|
||||
echo " <select class='formfld' name='user_setting_category' id='user_setting_category' onchange=\"$('#user_setting_subcategory').trigger('focus');\">\n";
|
||||
echo " <option value=''></option>\n";
|
||||
if (is_array($allowed_categories) && sizeof($allowed_categories) > 0) {
|
||||
foreach ($allowed_categories as $category) {
|
||||
@@ -534,7 +534,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
elseif ($category == "theme" && substr_count($subcategory, "_font") > 0 && $name == "text") {
|
||||
$row['user_setting_value'] = str_replace('"', "'", $row['user_setting_value']);
|
||||
if ($fonts = get_available_fonts('alpha')) {
|
||||
echo " <select class='formfld' id='sel_user_setting_value' onchange=\"if (this.selectedIndex == $('select#sel_user_setting_value option').length - 1) { $('#txt_user_setting_value').val('').fadeIn('fast'); $('#txt_user_setting_value').focus(); } else { $('#txt_user_setting_value').fadeOut('fast', function(){ $('#txt_user_setting_value').val($('#sel_user_setting_value').val()) }); } \">\n";
|
||||
echo " <select class='formfld' id='sel_user_setting_value' onchange=\"if (this.selectedIndex == $('select#sel_user_setting_value option').length - 1) { $('#txt_user_setting_value').val('').fadeIn('fast'); $('#txt_user_setting_value').trigger('focus'); } else { $('#txt_user_setting_value').fadeOut('fast', function(){ $('#txt_user_setting_value').val($('#sel_user_setting_value').val()) }); } \">\n";
|
||||
echo " <option value=''></option>\n";
|
||||
echo " <optgroup label='".$text['label-web_fonts']."'>\n";
|
||||
$option_found = false;
|
||||
@@ -714,7 +714,7 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
|
||||
echo "<script>\n";
|
||||
//capture enter key to submit form
|
||||
echo " $(window).keypress(function(event){\n";
|
||||
echo " $(window).on('keypress',function(event){\n";
|
||||
echo " if (event.which == 13) { submit_form(); }\n";
|
||||
echo " });\n";
|
||||
//hide/convert password fields then submit form
|
||||
@@ -724,9 +724,9 @@ if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
echo " $('form#frm').submit();\n";
|
||||
echo " }\n";
|
||||
//define lowercase class
|
||||
echo " $('.lowercase').blur(function(){ this.value = this.value.toLowerCase(); });";
|
||||
echo " $('.lowercase').on('blur',function(){ this.value = this.value.toLowerCase(); });";
|
||||
//show order if array
|
||||
echo " $('#user_setting_name').keyup(function(){ \n";
|
||||
echo " $('#user_setting_name').on('keyup',function(){ \n";
|
||||
echo " (this.value.toLowerCase() == 'array') ? $('#tr_order').slideDown('fast') : $('#tr_order').slideUp('fast');\n";
|
||||
echo " });\n";
|
||||
echo "</script>\n";
|
||||
|
||||
Reference in New Issue
Block a user