Absolutely Glamorous Custom Admin - Version 1.4.8.2

Version Description

  • Added check for non existing 'pagenow' GLOBAL variable
  • Using default WordPress theme when AGCA theme is activated
  • Fixed unknown font theme issue
  • Option to remove AGCA themes from admin bar
Download this release

Release Info

Developer argonius
Plugin Icon 128x128 Absolutely Glamorous Custom Admin
Version 1.4.8.2
Comparing to
See all releases

Code changes from version 1.4.8.1 to 1.4.8.2

plugin.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: AG Custom Admin
4
  Plugin URI: http://wordpressadminpanel.com/ag-custom-admin/
5
  Description: All-in-one tool for admin panel customization. Change almost everything: admin menu, dashboard, login page, admin bar etc. Apply admin panel themes.
6
  Author: Argonius
7
- Version: 1.4.8.1
8
  Author URI: http://www.argonius.com/
9
 
10
  Copyright 2015. Argonius (email : info@argonius.com)
@@ -53,11 +53,13 @@ class AGCA{
53
  add_action('wp_head', array(&$this,'print_page'));
54
  add_action( 'wp_before_admin_bar_render', array(&$this,'admin_bar_changes') );
55
  register_deactivation_hook(__FILE__, array(&$this,'agca_deactivate'));
56
-
 
 
57
  /*Initialize properties*/
58
  $this->colorizer = $this->jsonMenuArray(get_option('ag_colorizer_json'),'colorizer');
59
 
60
- $this->agca_version = "1.4.8.1";
61
 
62
  /*upload images programmaticaly*/
63
  //TODO upload with AJAX one by one, use post data to send urls one by one
@@ -87,6 +89,14 @@ class AGCA{
87
  return $links;
88
  }
89
 
 
 
 
 
 
 
 
 
90
  function agca_init_session(){
91
  if (!session_id())
92
  session_start();
@@ -311,11 +321,22 @@ class AGCA{
311
  echo "var agca_global_plugin_url = '".trailingslashit(plugins_url(basename(dirname(__FILE__))))."';";
312
  ?>
313
  </script>
314
- <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>style/ag_style.css?ver=<?php echo $this->agca_version; ?>" />
315
- <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>style/agca.css" />
316
  <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>require/dynamic.php?type=css&context=<?php echo $this->context; ?>&ver=<?php echo "changed_theme"; ?>" />
317
  <script type="text/javascript" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>script/ag_script.js?ver=<?php echo $this->agca_version; ?>"></script>
318
  <script type="text/javascript" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>require/dynamic.php?type=js&context=<?php echo $this->context; ?>&ver=<?php echo "changed_theme"; ?>"></script>
 
 
 
 
 
 
 
 
 
 
 
 
319
  <?php
320
  echo $this->templateCustomizations;
321
 
@@ -411,6 +432,7 @@ class AGCA{
411
  register_setting( 'agca-options-group', 'agca_admin_bar_new_content_user' );
412
  register_setting( 'agca-options-group', 'agca_admin_bar_new_content_media' );
413
  register_setting( 'agca-options-group', 'agca_admin_bar_update_notifications' );
 
414
  register_setting( 'agca-options-group', 'agca_remove_top_bar_dropdowns' );
415
  register_setting( 'agca-options-group', 'agca_admin_bar_frontend' );
416
  register_setting( 'agca-options-group', 'agca_admin_bar_frontend_hide' );
@@ -541,6 +563,7 @@ class AGCA{
541
  'agca_admin_bar_new_content_user',
542
  'agca_admin_bar_new_content_media',
543
  'agca_admin_bar_update_notifications',
 
544
  'agca_remove_top_bar_dropdowns',
545
  'agca_admin_menu_turnonoff',
546
  'agca_admin_menu_agca_button_only',
@@ -900,6 +923,9 @@ class AGCA{
900
  <?php if(get_option('agca_admin_bar_update_notifications')!=""){ ?>
901
  jQuery("ul#wp-admin-bar-root-default li#wp-admin-bar-updates").css("display","none");
902
  <?php } ?>
 
 
 
903
 
904
 
905
 
@@ -1107,8 +1133,10 @@ class AGCA{
1107
  //print_r(get_option( 'agca_templates' ));
1108
  $themes = get_option( 'agca_templates' );
1109
  $selectedTheme = get_option('agca_selected_template');
1110
- if(isset($themes[$selectedTheme])){
1111
  $theme = $themes[$selectedTheme];
 
 
1112
  echo (stripslashes($theme['common']));
1113
  echo "<!--AGCAIMAGES: ".$theme['images']."-->";
1114
 
@@ -2036,6 +2064,14 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
2036
  <input class="agca-checkbox" title="Removes update notifications from admin bar" type="checkbox" name="agca_admin_bar_update_notifications" value="true" <?php if (get_option('agca_admin_bar_update_notifications')==true) echo 'checked="checked" '; ?> />
2037
  </td>
2038
  </tr>
 
 
 
 
 
 
 
 
2039
  <tr valign="center">
2040
  <th scope="row">
2041
  <label title="Adds custom text in admin top bar. Default Wordpress heading stays intact." for="agca_custom_site_heading">Custom blog heading</label>
4
  Plugin URI: http://wordpressadminpanel.com/ag-custom-admin/
5
  Description: All-in-one tool for admin panel customization. Change almost everything: admin menu, dashboard, login page, admin bar etc. Apply admin panel themes.
6
  Author: Argonius
7
+ Version: 1.4.8.2
8
  Author URI: http://www.argonius.com/
9
 
10
  Copyright 2015. Argonius (email : info@argonius.com)
53
  add_action('wp_head', array(&$this,'print_page'));
54
  add_action( 'wp_before_admin_bar_render', array(&$this,'admin_bar_changes') );
55
  register_deactivation_hook(__FILE__, array(&$this,'agca_deactivate'));
56
+
57
+ add_action( 'customize_controls_enqueue_scripts', array(&$this,'agca_customizer_php') );
58
+
59
  /*Initialize properties*/
60
  $this->colorizer = $this->jsonMenuArray(get_option('ag_colorizer_json'),'colorizer');
61
 
62
+ $this->agca_version = "1.4.8.2";
63
 
64
  /*upload images programmaticaly*/
65
  //TODO upload with AJAX one by one, use post data to send urls one by one
89
  return $links;
90
  }
91
 
92
+ function change_admin_color(){
93
+ return 'default';
94
+ }
95
+
96
+ function agca_customizer_php(){
97
+ $this->agca_get_includes();
98
+ }
99
+
100
  function agca_init_session(){
101
  if (!session_id())
102
  session_start();
321
  echo "var agca_global_plugin_url = '".trailingslashit(plugins_url(basename(dirname(__FILE__))))."';";
322
  ?>
323
  </script>
324
+ <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>style/ag_style.css?ver=<?php echo $this->agca_version; ?>" />
 
325
  <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>require/dynamic.php?type=css&context=<?php echo $this->context; ?>&ver=<?php echo "changed_theme"; ?>" />
326
  <script type="text/javascript" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>script/ag_script.js?ver=<?php echo $this->agca_version; ?>"></script>
327
  <script type="text/javascript" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>require/dynamic.php?type=js&context=<?php echo $this->context; ?>&ver=<?php echo "changed_theme"; ?>"></script>
328
+
329
+ <?php
330
+ if($this->context == "login"){
331
+ ?>
332
+ <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>style/login.min.css" />
333
+ <?php
334
+ }else{
335
+ ?>
336
+ <link rel="stylesheet" type="text/css" href="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>style/admin.min.css" />
337
+ <?php
338
+ }
339
+ ?>
340
  <?php
341
  echo $this->templateCustomizations;
342
 
432
  register_setting( 'agca-options-group', 'agca_admin_bar_new_content_user' );
433
  register_setting( 'agca-options-group', 'agca_admin_bar_new_content_media' );
434
  register_setting( 'agca-options-group', 'agca_admin_bar_update_notifications' );
435
+ register_setting( 'agca-options-group', 'agca_admin_bar_admin_themes' );
436
  register_setting( 'agca-options-group', 'agca_remove_top_bar_dropdowns' );
437
  register_setting( 'agca-options-group', 'agca_admin_bar_frontend' );
438
  register_setting( 'agca-options-group', 'agca_admin_bar_frontend_hide' );
563
  'agca_admin_bar_new_content_user',
564
  'agca_admin_bar_new_content_media',
565
  'agca_admin_bar_update_notifications',
566
+ 'agca_admin_bar_admin_themes',
567
  'agca_remove_top_bar_dropdowns',
568
  'agca_admin_menu_turnonoff',
569
  'agca_admin_menu_agca_button_only',
923
  <?php if(get_option('agca_admin_bar_update_notifications')!=""){ ?>
924
  jQuery("ul#wp-admin-bar-root-default li#wp-admin-bar-updates").css("display","none");
925
  <?php } ?>
926
+ <?php if(get_option('agca_admin_bar_admin_themes')!=""){ ?>
927
+ jQuery("ul#wp-admin-bar-root-default li#wp-admin-bar-agca-admin-themes").css("display","none");
928
+ <?php } ?>
929
 
930
 
931
 
1133
  //print_r(get_option( 'agca_templates' ));
1134
  $themes = get_option( 'agca_templates' );
1135
  $selectedTheme = get_option('agca_selected_template');
1136
+ if(isset($themes[$selectedTheme])){
1137
  $theme = $themes[$selectedTheme];
1138
+ add_filter('get_user_option_admin_color', array(&$this,'change_admin_color'));
1139
+
1140
  echo (stripslashes($theme['common']));
1141
  echo "<!--AGCAIMAGES: ".$theme['images']."-->";
1142
 
2064
  <input class="agca-checkbox" title="Removes update notifications from admin bar" type="checkbox" name="agca_admin_bar_update_notifications" value="true" <?php if (get_option('agca_admin_bar_update_notifications')==true) echo 'checked="checked" '; ?> />
2065
  </td>
2066
  </tr>
2067
+ <tr valign="center">
2068
+ <th >
2069
+ <label title="Remove 'Admin themes' from admin bar" for="agca_admin_bar_admin_themes">Remove "Admin themes" from admin bar</label>
2070
+ </th>
2071
+ <td>
2072
+ <input class="agca-checkbox" title="Remove 'Admin themes' from admin bar" type="checkbox" name="agca_admin_bar_admin_themes" value="true" <?php if (get_option('agca_admin_bar_admin_themes')==true) echo 'checked="checked" '; ?> />
2073
+ </td>
2074
+ </tr>
2075
  <tr valign="center">
2076
  <th scope="row">
2077
  <label title="Adds custom text in admin top bar. Default Wordpress heading stays intact." for="agca_custom_site_heading">Custom blog heading</label>
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://wordpressadminpanel.com/ag-custom-admin/
4
  Tags: admin, customize, hide, change admin, themes, admin themes, admin bar, login page
5
  Requires at least: 3.0
6
  Tested up to: 4.2.2
7
- Stable tag: 1.4.8.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -154,6 +154,12 @@ Plugin should be always up-to-date with latest WordPress release. If you have fo
154
 
155
  == Changelog ==
156
 
 
 
 
 
 
 
157
  = 1.4.8.1 =
158
  * Small bug fix
159
 
@@ -434,6 +440,12 @@ Plugin should be always up-to-date with latest WordPress release. If you have fo
434
 
435
  == Upgrade Notice ==
436
 
 
 
 
 
 
 
437
  = 1.4.8.1 =
438
  * Small bug fix
439
 
4
  Tags: admin, customize, hide, change admin, themes, admin themes, admin bar, login page
5
  Requires at least: 3.0
6
  Tested up to: 4.2.2
7
+ Stable tag: 1.4.8.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
154
 
155
  == Changelog ==
156
 
157
+ = 1.4.8.2 =
158
+ * Added check for non existing 'pagenow' GLOBAL variable
159
+ * Using default WordPress theme when AGCA theme is activated
160
+ * Fixed unknown font theme issue
161
+ * Option to remove AGCA themes from admin bar
162
+
163
  = 1.4.8.1 =
164
  * Small bug fix
165
 
440
 
441
  == Upgrade Notice ==
442
 
443
+ = 1.4.8.2 =
444
+ * Added check for non existing 'pagenow' GLOBAL variable
445
+ * Using default WordPress theme when AGCA theme is activated
446
+ * Fixed unknown font theme issue
447
+ * Option to remove AGCA themes from admin bar
448
+
449
  = 1.4.8.1 =
450
  * Small bug fix
451
 
require/dynamic.php CHANGED
@@ -37,7 +37,7 @@ if ( $agcaContext != "login" && !is_user_logged_in()) {
37
  $adminscript = stripslashes($theme[$optionName]);
38
  $settings = $theme['settings'];
39
  if($settings == "" || $settings == " ") $settings = "{}";
40
- $adminscript = agcaAppendSettingsToAGCATemplateCustomizations(stripslashes($adminscript), $settings);
41
  $admindata = agcaEnableSpecificWPVersionCustomizations($admindata);
42
  $admindata = agcaRemoveCSSComments($admindata);
43
 
37
  $adminscript = stripslashes($theme[$optionName]);
38
  $settings = $theme['settings'];
39
  if($settings == "" || $settings == " ") $settings = "{}";
40
+ $adminscript = agcaAppendSettingsToAGCATemplateCustomizations($adminscript, $settings);
41
  $admindata = agcaEnableSpecificWPVersionCustomizations($admindata);
42
  $admindata = agcaRemoveCSSComments($admindata);
43
 
style/{agca.css → admin.css} RENAMED
File without changes
style/admin.min.css ADDED
File without changes
style/login.css ADDED
File without changes
style/login.min.css ADDED
File without changes
uninstall.php CHANGED
@@ -58,6 +58,7 @@
58
  delete_option( 'agca_admin_bar_new_content_user' );
59
  delete_option( 'agca_admin_bar_new_content_media' );
60
  delete_option( 'agca_admin_bar_update_notifications' );
 
61
  delete_option( 'agca_remove_top_bar_dropdowns' );
62
 
63
  /*Admin menu*/
58
  delete_option( 'agca_admin_bar_new_content_user' );
59
  delete_option( 'agca_admin_bar_new_content_media' );
60
  delete_option( 'agca_admin_bar_update_notifications' );
61
+ delete_option( 'agca_admin_bar_admin_themes' );
62
  delete_option( 'agca_remove_top_bar_dropdowns' );
63
 
64
  /*Admin menu*/