Changeset 2857421
- Timestamp:
- 01/31/2023 02:54:35 AM (3 years ago)
- Location:
- fiber-admin
- Files:
-
- 12 edited
- 1 copied
-
tags/2.0.15 (copied) (copied from fiber-admin/trunk)
-
tags/2.0.15/changelog.txt (modified) (1 diff)
-
tags/2.0.15/fiberadmin.php (modified) (1 diff)
-
tags/2.0.15/includes/content.php (modified) (2 diffs)
-
tags/2.0.15/includes/default.php (modified) (3 diffs)
-
tags/2.0.15/includes/settings/white-label.php (modified) (2 diffs)
-
tags/2.0.15/readme.txt (modified) (2 diffs)
-
trunk/changelog.txt (modified) (1 diff)
-
trunk/fiberadmin.php (modified) (1 diff)
-
trunk/includes/content.php (modified) (2 diffs)
-
trunk/includes/default.php (modified) (3 diffs)
-
trunk/includes/settings/white-label.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
fiber-admin/tags/2.0.15/changelog.txt
r2834904 r2857421 1 1 == Changelog == 2 3 = 2.0.15 = 4 *Release Date - 31 January 2023* 5 6 * Fixed: Skip auto replace email address if the content has email in HTML attribute. 7 * Added: Add option to toggle admin toolbar. 2 8 3 9 = 2.0.14 = -
fiber-admin/tags/2.0.15/fiberadmin.php
r2834904 r2857421 4 4 * Plugin URI: https://wordpress.org/plugins/fiber-admin/ 5 5 * Description: 💈 Bring multiple customization features to make your own WordPress admin. 6 * Version: 2.0.1 46 * Version: 2.0.15 7 7 * Requires at least: 5.2 8 8 * Requires PHP: 7.0 -
fiber-admin/tags/2.0.15/includes/content.php
r2630321 r2857421 47 47 48 48 public function fiad_auto_convert_email_address($content){ 49 // Skip if the content has mailto link or input type email 50 if(strpos($content, 'mailto') !== false || strpos($content, 'type="email"') !== false){ 49 $enable_auto_convert = true; 50 51 // Skip if the content has mailto link 52 if(strpos($content, 'mailto') !== false){ 53 return $content; 54 } 55 56 // Skip if the content has email in HTML attribute 57 $att_email_regex = '/<\w+.*?\K[\w-]+=["\']*\s*(?:\w+\s*)*[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}\s*(?:[\'"]?(?:\w+\s*)*[\'"]?)?["\']*(?=.*?>)/mi'; 58 preg_match($att_email_regex, $content, $email_matches); 59 if($email_matches){ 60 $enable_auto_convert = false; 61 } 62 63 // Skip replace email address 64 if(!$enable_auto_convert){ 51 65 return $content; 52 66 } … … 54 68 // Detect and create email link 55 69 $search = array('/([a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4})/'); 56 $replace = array('<a href="mailto:$1" >$1</a>');70 $replace = array('<a href="mailto:$1" title="$1">$1</a>'); 57 71 58 72 return preg_replace($search, $replace, $content); -
fiber-admin/tags/2.0.15/includes/default.php
r2673225 r2857421 10 10 class Fiber_Admin_Default{ 11 11 public function __construct(){ 12 // default value12 //white label 13 13 if(fiad_get_general_option('hide_wordpress_branding')){ 14 14 // Replace "WordPress" in the page titles. … … 37 37 add_action('login_enqueue_scripts', array($this, 'fiad_remove_backtoblog')); 38 38 39 // Hide Admin Bar Frontend for all users 40 add_filter('show_admin_bar', '__return_false'); 39 // Hide / Show Admin Bar Frontend for all users 40 if(fiad_get_general_option('enable_admin_toolbar')){ 41 add_filter('show_admin_bar', '__return_true'); 42 }else{ 43 add_filter('show_admin_bar', '__return_false'); 44 add_action('wp_print_styles', array($this, 'fiad_deregister_styles'), 100); 45 } 41 46 42 47 // Remove WordPress admin bar logo … … 161 166 .wp-admin #wpadminbar #wp-admin-bar-site-name>.ab-item:before{ 162 167 content:""; 163 background:transparent url("' .get_site_icon_url().'") no-repeat center/contain !important;168 background:transparent url("' . get_site_icon_url() . '") no-repeat center/contain !important; 164 169 width: 20px; height: 20px; 165 170 } 166 171 </style>'; 167 172 } 173 174 public function fiad_deregister_styles(){ 175 wp_deregister_style('dashicons'); 176 } 168 177 } 169 178 -
fiber-admin/tags/2.0.15/includes/settings/white-label.php
r2727158 r2857421 51 51 ); 52 52 53 add_settings_field( 54 'enable_admin_toolbar', // id 55 'Enable Admin Toolbar', // title 56 array($this, 'fiad_enable_admin_toolbar'), // callback 57 'fiber-admin-white-label', // page 58 'fiad_branding_section' // section 59 ); 60 53 61 add_settings_section( 54 62 'fiad_white_label_section', … … 116 124 <input type="checkbox" name="fiber_admin[hide_wordpress_branding]" id="hide_wordpress_branding" 117 125 value="yes" <?php checked(esc_attr(fiad_get_general_option('hide_wordpress_branding')), 'yes'); ?> /> 126 <span class="slider round"></span> 127 </label> 128 </fieldset> 129 <?php 130 } 131 132 public function fiad_enable_admin_toolbar(){ 133 ?> 134 <fieldset> 135 <label for="enable_admin_toolbar" class="fiber-admin-toggle"> 136 <input type="checkbox" name="fiber_admin[enable_admin_toolbar]" id="enable_admin_toolbar" 137 value="yes" <?php checked(esc_attr(fiad_get_general_option('enable_admin_toolbar')), 'yes'); ?> /> 118 138 <span class="slider round"></span> 119 139 </label> -
fiber-admin/tags/2.0.15/readme.txt
r2834904 r2857421 5 5 Tested up to: 6.0.1 6 6 Requires PHP: 7.0 7 Stable tag: 2.0.1 47 Stable tag: 2.0.15 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 47 47 == Changelog == 48 48 49 = 2.0.1 4=50 *Release Date - 16 December 2022*49 = 2.0.15 = 50 *Release Date - 31 January 2023* 51 51 52 * Fixed: Fix error when other plugins include SVG library. 53 * Fixed: Prevent to change the passed orderby in admin. 54 * Fixed: Fix wrong param in `simplexml_load_file` function. 52 * Fixed: Skip auto replace email address if the content has email in HTML attribute. 53 * Added: Add option to toggle admin toolbar. -
fiber-admin/trunk/changelog.txt
r2834904 r2857421 1 1 == Changelog == 2 3 = 2.0.15 = 4 *Release Date - 31 January 2023* 5 6 * Fixed: Skip auto replace email address if the content has email in HTML attribute. 7 * Added: Add option to toggle admin toolbar. 2 8 3 9 = 2.0.14 = -
fiber-admin/trunk/fiberadmin.php
r2834904 r2857421 4 4 * Plugin URI: https://wordpress.org/plugins/fiber-admin/ 5 5 * Description: 💈 Bring multiple customization features to make your own WordPress admin. 6 * Version: 2.0.1 46 * Version: 2.0.15 7 7 * Requires at least: 5.2 8 8 * Requires PHP: 7.0 -
fiber-admin/trunk/includes/content.php
r2630321 r2857421 47 47 48 48 public function fiad_auto_convert_email_address($content){ 49 // Skip if the content has mailto link or input type email 50 if(strpos($content, 'mailto') !== false || strpos($content, 'type="email"') !== false){ 49 $enable_auto_convert = true; 50 51 // Skip if the content has mailto link 52 if(strpos($content, 'mailto') !== false){ 53 return $content; 54 } 55 56 // Skip if the content has email in HTML attribute 57 $att_email_regex = '/<\w+.*?\K[\w-]+=["\']*\s*(?:\w+\s*)*[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}\s*(?:[\'"]?(?:\w+\s*)*[\'"]?)?["\']*(?=.*?>)/mi'; 58 preg_match($att_email_regex, $content, $email_matches); 59 if($email_matches){ 60 $enable_auto_convert = false; 61 } 62 63 // Skip replace email address 64 if(!$enable_auto_convert){ 51 65 return $content; 52 66 } … … 54 68 // Detect and create email link 55 69 $search = array('/([a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4})/'); 56 $replace = array('<a href="mailto:$1" >$1</a>');70 $replace = array('<a href="mailto:$1" title="$1">$1</a>'); 57 71 58 72 return preg_replace($search, $replace, $content); -
fiber-admin/trunk/includes/default.php
r2673225 r2857421 10 10 class Fiber_Admin_Default{ 11 11 public function __construct(){ 12 // default value12 //white label 13 13 if(fiad_get_general_option('hide_wordpress_branding')){ 14 14 // Replace "WordPress" in the page titles. … … 37 37 add_action('login_enqueue_scripts', array($this, 'fiad_remove_backtoblog')); 38 38 39 // Hide Admin Bar Frontend for all users 40 add_filter('show_admin_bar', '__return_false'); 39 // Hide / Show Admin Bar Frontend for all users 40 if(fiad_get_general_option('enable_admin_toolbar')){ 41 add_filter('show_admin_bar', '__return_true'); 42 }else{ 43 add_filter('show_admin_bar', '__return_false'); 44 add_action('wp_print_styles', array($this, 'fiad_deregister_styles'), 100); 45 } 41 46 42 47 // Remove WordPress admin bar logo … … 161 166 .wp-admin #wpadminbar #wp-admin-bar-site-name>.ab-item:before{ 162 167 content:""; 163 background:transparent url("' .get_site_icon_url().'") no-repeat center/contain !important;168 background:transparent url("' . get_site_icon_url() . '") no-repeat center/contain !important; 164 169 width: 20px; height: 20px; 165 170 } 166 171 </style>'; 167 172 } 173 174 public function fiad_deregister_styles(){ 175 wp_deregister_style('dashicons'); 176 } 168 177 } 169 178 -
fiber-admin/trunk/includes/settings/white-label.php
r2727158 r2857421 51 51 ); 52 52 53 add_settings_field( 54 'enable_admin_toolbar', // id 55 'Enable Admin Toolbar', // title 56 array($this, 'fiad_enable_admin_toolbar'), // callback 57 'fiber-admin-white-label', // page 58 'fiad_branding_section' // section 59 ); 60 53 61 add_settings_section( 54 62 'fiad_white_label_section', … … 116 124 <input type="checkbox" name="fiber_admin[hide_wordpress_branding]" id="hide_wordpress_branding" 117 125 value="yes" <?php checked(esc_attr(fiad_get_general_option('hide_wordpress_branding')), 'yes'); ?> /> 126 <span class="slider round"></span> 127 </label> 128 </fieldset> 129 <?php 130 } 131 132 public function fiad_enable_admin_toolbar(){ 133 ?> 134 <fieldset> 135 <label for="enable_admin_toolbar" class="fiber-admin-toggle"> 136 <input type="checkbox" name="fiber_admin[enable_admin_toolbar]" id="enable_admin_toolbar" 137 value="yes" <?php checked(esc_attr(fiad_get_general_option('enable_admin_toolbar')), 'yes'); ?> /> 118 138 <span class="slider round"></span> 119 139 </label> -
fiber-admin/trunk/readme.txt
r2834904 r2857421 5 5 Tested up to: 6.0.1 6 6 Requires PHP: 7.0 7 Stable tag: 2.0.1 47 Stable tag: 2.0.15 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 47 47 == Changelog == 48 48 49 = 2.0.1 4=50 *Release Date - 16 December 2022*49 = 2.0.15 = 50 *Release Date - 31 January 2023* 51 51 52 * Fixed: Fix error when other plugins include SVG library. 53 * Fixed: Prevent to change the passed orderby in admin. 54 * Fixed: Fix wrong param in `simplexml_load_file` function. 52 * Fixed: Skip auto replace email address if the content has email in HTML attribute. 53 * Added: Add option to toggle admin toolbar.
Note: See TracChangeset
for help on using the changeset viewer.