Version Description
- WordPress 3.5 compatible
- Added login page background color
- Resolving jQuery script
- Added feedback buttons (postitive/negative)
- Better user's experience (updated form buttons and textboxes)
- Fixed problem with Howdy renaming
Download this release
Release Info
Developer | argonius |
Plugin | Absolutely Glamorous Custom Admin |
Version | 1.2.7 |
Comparing to | |
See all releases |
Code changes from version 1.2.6.5 to 1.2.7
- images/thumbdown.png +0 -0
- images/thumbup.png +0 -0
- plugin.php +186 -133
- readme.txt +30 -7
- script/ag_script.js +127 -24
- style/ag_style.css +41 -1
images/thumbdown.png
ADDED
Binary file
|
images/thumbup.png
ADDED
Binary file
|
plugin.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
Plugin Name: AG Custom Admin
|
4 |
-
Plugin URI: http://
|
5 |
Description: Hide or change items in admin panel. Customize buttons from admin menu. Colorize admin and login page with custom colors.
|
6 |
Author: Argonius
|
7 |
-
Version: 1.2.
|
8 |
-
Author URI: http://
|
9 |
|
10 |
Copyright 2011. Argonius (email : info@argonius.com)
|
11 |
|
@@ -27,7 +27,7 @@ Author URI: http://wordpress.argonius.com/ag-custom-admin
|
|
27 |
//fb($_POST);
|
28 |
|
29 |
$agca = new AGCA();
|
30 |
-
|
31 |
class AGCA{
|
32 |
private $colorizer="";
|
33 |
private $active_plugin;
|
@@ -36,22 +36,23 @@ class AGCA{
|
|
36 |
private $context = "";
|
37 |
private $saveAfterImport = false;
|
38 |
public function __construct()
|
39 |
-
{
|
40 |
-
|
|
|
|
|
41 |
add_filter('plugin_row_meta', array(&$this,'jk_filter_plugin_links'), 10, 2);
|
42 |
add_action('admin_init', array(&$this,'agca_register_settings'));
|
43 |
add_action('admin_head', array(&$this,'print_admin_css'));
|
44 |
add_action('login_head', array(&$this,'print_login_head'));
|
45 |
add_action('admin_menu', array(&$this,'agca_create_menu'));
|
46 |
add_action('wp_head', array(&$this,'print_page'));
|
47 |
-
register_deactivation_hook(__FILE__, array(&$this,'agca_deactivate'));
|
48 |
-
|
49 |
|
50 |
|
51 |
/*Initialize properties*/
|
52 |
$this->colorizer = $this->jsonMenuArray(get_option('ag_colorizer_json'),'colorizer');
|
53 |
//fb($this->colorizer);
|
54 |
-
$this->agca_version = "1.2.
|
55 |
}
|
56 |
// Add donate and support information
|
57 |
function jk_filter_plugin_links($links, $file)
|
@@ -59,8 +60,8 @@ class AGCA{
|
|
59 |
if ( $file == plugin_basename(__FILE__) )
|
60 |
{
|
61 |
$links[] = '<a href="tools.php?page=ag-custom-admin/plugin.php">' . __('Settings') . '</a>';
|
62 |
-
$links[] = '<a href="http://
|
63 |
-
$links[] = '<a href="http://
|
64 |
}
|
65 |
return $links;
|
66 |
}
|
@@ -107,9 +108,9 @@ class AGCA{
|
|
107 |
}
|
108 |
|
109 |
function reloadScript(){
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
}
|
114 |
|
115 |
function agca_register_settings() {
|
@@ -417,6 +418,7 @@ class AGCA{
|
|
417 |
|
418 |
function agca_create_admin_button($name,$arr) {
|
419 |
$class="";
|
|
|
420 |
$href = $arr["value"];
|
421 |
$target =$arr["target"];;
|
422 |
if($name == 'AG Custom Admin'){
|
@@ -424,11 +426,20 @@ class AGCA{
|
|
424 |
$target = "_self";
|
425 |
$href = $arr;
|
426 |
}
|
427 |
-
|
428 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
429 |
$button .= '<div class="wp-menu-toggle" style="display: none;"><br></div>';
|
430 |
$button .= '<a tabindex="1" target="'.$target.'" class="menu-top menu-top-last" href="'.$href.'">'.$name.'</a>';
|
431 |
-
|
|
|
432 |
|
433 |
return $button;
|
434 |
}
|
@@ -533,7 +544,7 @@ class AGCA{
|
|
533 |
//only output the script once..
|
534 |
jQueryScriptOutputted = true;
|
535 |
//output the script (load it from google api)
|
536 |
-
document.write("<scr" + "ipt type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.
|
537 |
}
|
538 |
setTimeout("initJQuery()", 50);
|
539 |
} else {
|
@@ -732,7 +743,17 @@ class AGCA{
|
|
732 |
|
733 |
<?php } ?>
|
734 |
<?php if(get_option('agca_howdy')!=""){ ?>
|
735 |
-
if(isWPHigherOrEqualThan("3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
736 |
var alltext="";
|
737 |
alltext="";
|
738 |
jQuery('li#wp-admin-bar-my-account').css('cursor','default');
|
@@ -757,7 +778,14 @@ class AGCA{
|
|
757 |
if(howdyText !=null){
|
758 |
jQuery("#user_info").html("<p>"+"<?php echo get_option('agca_howdy'); ?>"+howdyText.substr(9));
|
759 |
}
|
760 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
761 |
<?php } ?>
|
762 |
<?php if(get_option('agca_logout')!=""){ ?>
|
763 |
if(isWPHigherOrEqualThan("3.3")){
|
@@ -880,6 +908,7 @@ var agca_version = "<?php echo $this->agca_version; ?>";
|
|
880 |
var errors = false;
|
881 |
var isSettingsImport = false;
|
882 |
var agca_context = "admin";
|
|
|
883 |
|
884 |
<?php
|
885 |
if(isset($_POST['_agca_import_settings']) && $_POST['_agca_import_settings']=='true'){
|
@@ -923,12 +952,15 @@ try
|
|
923 |
<?php $buttonsJq = $this->jsonMenuArray(get_option('ag_add_adminmenu_json'),'buttonsJq'); ?>
|
924 |
var buttonsJq = '<?php echo $buttonsJq; ?>';
|
925 |
|
926 |
-
|
927 |
-
|
|
|
928 |
createEditMenuPageV32(checkboxes,textboxes);
|
929 |
<?php }else{ ?>
|
930 |
createEditMenuPage(checkboxes,textboxes);
|
931 |
<?php } ?>
|
|
|
|
|
932 |
|
933 |
<?php
|
934 |
//if admin, and option to hide settings for admin is set
|
@@ -959,7 +991,10 @@ try
|
|
959 |
<?php } ?>
|
960 |
|
961 |
<?php if(get_option('agca_admin_menu_submenu_round')==true){ ?>
|
962 |
-
jQuery("#adminmenu
|
|
|
|
|
|
|
963 |
<?php } ?>
|
964 |
|
965 |
<?php $this->print_admin_bar_scripts(); ?>
|
@@ -996,7 +1031,7 @@ try
|
|
996 |
<?php } ?>
|
997 |
|
998 |
<?php if(get_option('agca_footer')==true){ ?>
|
999 |
-
jQuery("#footer").css("display","none");
|
1000 |
<?php } ?>
|
1001 |
|
1002 |
|
@@ -1111,10 +1146,7 @@ try
|
|
1111 |
|
1112 |
<?php /*If Turned on*/ ?>
|
1113 |
|
1114 |
-
|
1115 |
-
if (current_user_can($this->admin_capability())){ ?>
|
1116 |
-
jQuery('#adminmenu').append('<?php echo $this->agca_create_admin_button('AG Custom Admin','tools.php?page=ag-custom-admin/plugin.php'); ?>');
|
1117 |
-
<?php } ?>
|
1118 |
|
1119 |
<?php if(get_option('agca_admin_menu_agca_button_only') == true){ ?>
|
1120 |
jQuery('#adminmenu > li').each(function(){
|
@@ -1122,7 +1154,12 @@ try
|
|
1122 |
jQuery(this).addClass('noclass');
|
1123 |
}
|
1124 |
});
|
1125 |
-
<?php } ?>
|
|
|
|
|
|
|
|
|
|
|
1126 |
|
1127 |
<?php /*EDIT MENU ITEMS*/?>
|
1128 |
<?php if(get_option('ag_edit_adminmenu_json')!=""){
|
@@ -1151,8 +1188,15 @@ try
|
|
1151 |
if(checkboxes[i][0].indexOf("<-TOP->") >=0){ //if it is top item
|
1152 |
if(checkboxes[i][0].indexOf(topmenuitem) >0){//if found match in menu, with top item in array
|
1153 |
matchFound = true;
|
1154 |
-
//console.log(checkboxes[i][0]);
|
1155 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1156 |
if((checkboxes[i][1] == "true") || (checkboxes[i][1] == "checked")){
|
1157 |
jQuery(this).addClass('noclass');
|
1158 |
}
|
@@ -1161,8 +1205,20 @@ try
|
|
1161 |
var selector = '#' + topmenuitem + ' ul li';
|
1162 |
//console.log(i+" "+checkboxes);
|
1163 |
while((i<checkboxes.length) && (checkboxes[i][0].indexOf("<-TOP->") < 0)){
|
1164 |
-
jQuery(selector).each(function(){ //loop through all submenus
|
1165 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1166 |
if((checkboxes[i][1] == "true") || (checkboxes[i][1] == "checked")){
|
1167 |
jQuery(this).addClass('noclass');
|
1168 |
}
|
@@ -1231,7 +1287,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1231 |
$this->updateAllColors();
|
1232 |
}else{
|
1233 |
?>function updateAllColors(){}; <?php
|
1234 |
-
} ?>
|
1235 |
|
1236 |
|
1237 |
/* ]]> */
|
@@ -1254,10 +1310,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1254 |
}
|
1255 |
|
1256 |
function print_login_head(){
|
1257 |
-
$this->context = "login";
|
1258 |
-
if( !wp_script_is('jquery')) {
|
1259 |
-
$this->reloadScript();
|
1260 |
-
}
|
1261 |
$this->agca_get_includes();
|
1262 |
$wpversion = $this->get_wp_version();
|
1263 |
?>
|
@@ -1345,13 +1398,13 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1345 |
jQuery('label,h1,h2,h3,h4,h5,h6,a,p,.form-table th,.form-wrap label').css('text-shadow','none');
|
1346 |
|
1347 |
if(isWPHigherOrEqualThan("3.3")){
|
1348 |
-
jQuery("body.login").css("background","<?php echo $this->colorizer['
|
1349 |
}else{
|
1350 |
|
1351 |
<?php
|
1352 |
-
if($this->colorizer['
|
1353 |
?>
|
1354 |
-
updateTargetColor("
|
1355 |
|
1356 |
<?php
|
1357 |
}
|
@@ -1413,14 +1466,16 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1413 |
<form method="post" id="agca_form" action="options.php">
|
1414 |
<?php settings_fields( 'agca-options-group' ); ?>
|
1415 |
<table>
|
1416 |
-
<tr valign="
|
1417 |
<th scope="row">
|
1418 |
-
|
1419 |
</th>
|
1420 |
<td><input title="If checked, all users will be affected with these changes, except admin. Not checked = apply for all" type="checkbox" name="agca_role_allbutadmin" value="true" <?php if (get_option('agca_role_allbutadmin')==true) echo 'checked="checked" '; echo get_option('agca_role_allbutadmin'); ?> />
|
1421 |
</td>
|
1422 |
-
</tr>
|
1423 |
-
</table>
|
|
|
|
|
1424 |
<br />
|
1425 |
<ul id="ag_main_menu">
|
1426 |
<li class="selected"><a href="#admin-bar-settings" title="Settings for admin bar" >Admin Bar</a></li>
|
@@ -1430,8 +1485,8 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1430 |
<li class="normal" ><a href="#admin-menu-settings" title="Settings for main admin menu">Admin Menu</a></li>
|
1431 |
<li class="normal"><a href="#ag-colorizer-setttings" title="AG colorizer settings">Colorizer</a></li>
|
1432 |
<li class="normal"><a href="#ag-advanced" title="My custom scripts">Advanced</a></li>
|
1433 |
-
<li style="background:none;border:none;padding:0;"><a id="agca_donate_button" style="margin-left:8px" title="Like this plugin? You can support its future development by giving a donation by your wish " href="http://
|
1434 |
-
</li>
|
1435 |
<li style="background:none;border:none;padding:0;padding-left:10px;margin-top:-7px"></li>
|
1436 |
</ul>
|
1437 |
<div id="agca_advertising">
|
@@ -1469,6 +1524,22 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1469 |
<input type="checkbox" title='Check this if you want to show Log Out button in top right corner of admin page' name="agca_header_show_logout" value="true" <?php if ((get_option('agca_header')==true) && (get_option('agca_header_show_logout')==true)) echo 'checked="checked" '; ?> />
|
1470 |
</td>
|
1471 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1472 |
<tr valign="center">
|
1473 |
<td colspan="2">
|
1474 |
<div class="ag_table_heading"><h3 tabindex="0">Elements on Left</h3></div>
|
@@ -1484,29 +1555,13 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1484 |
<input type="checkbox" title="This is link next to heading in admin bar" name="agca_privacy_options" value="true" <?php if (get_option('agca_privacy_options')==true) echo 'checked="checked" '; ?> />
|
1485 |
</td>
|
1486 |
</tr>
|
1487 |
-
<?php } ?>
|
1488 |
-
<tr valign="center" >
|
1489 |
-
<td>
|
1490 |
-
<label tabindex="0" title="Removes admin bar customizations (AGCA scripts) on front end." for="agca_admin_bar_frontend">Remove admin bar customizations on site pages</label>
|
1491 |
-
</td>
|
1492 |
-
<td>
|
1493 |
-
<input id="agca_admin_bar_frontend" type="checkbox" title="Removes admin bar customizations (AGCA scripts) on front end." name="agca_admin_bar_frontend" value="true" <?php if (get_option('agca_admin_bar_frontend')==true) echo 'checked="checked" '; ?> />
|
1494 |
-
</td>
|
1495 |
-
</tr>
|
1496 |
-
<tr valign="center" >
|
1497 |
-
<td>
|
1498 |
-
<label tabindex="0" title="Removes admin bar on front end." for="agca_admin_bar_frontend_hide">Remove admin bar on site pages</label>
|
1499 |
-
</td>
|
1500 |
-
<td>
|
1501 |
-
<input id="agca_admin_bar_frontend_hide" type="checkbox" title="Removes admin bar on front end." name="agca_admin_bar_frontend_hide" value="true" <?php if (get_option('agca_admin_bar_frontend_hide')==true) echo 'checked="checked" '; ?> />
|
1502 |
-
</td>
|
1503 |
-
</tr>
|
1504 |
<tr valign="center">
|
1505 |
<th >
|
1506 |
<label title="Change default WordPress logo with custom image." for="agca_wp_logo_custom">Change admin bar logo</label>
|
1507 |
</th>
|
1508 |
<td>
|
1509 |
-
<input id="agca_wp_logo_custom" title="If this field is not empty, image from provided url will be visible in top bar" type="text" size="47" name="agca_wp_logo_custom" value="<?php echo get_option('agca_wp_logo_custom'); ?>" /><input type="button"
|
1510 |
<p><i>Put here an URL of the new top bar image ( maximum height = 28px)</i>.</p>
|
1511 |
</td>
|
1512 |
</tr>
|
@@ -1515,7 +1570,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1515 |
<label title="Change admin bar logo link.</br></br>Use:</br><strong>%BLOG%</strong> - for blog URL</br><strong>%SWITCH%</strong> - to switch betweent admin and site area" for="agca_wp_logo_custom">Change admin bar logo link</label>
|
1516 |
</th>
|
1517 |
<td>
|
1518 |
-
<input id="agca_wp_logo_custom_link" type="text" size="47" name="agca_wp_logo_custom_link" value="<?php echo get_option('agca_wp_logo_custom_link'); ?>" /><input type="button" onClick="jQuery('#agca_wp_logo_custom_link').val('');" value="Clear" />
|
1519 |
<p><i>Put here a link for admin bar logo </i>.</p>
|
1520 |
</td>
|
1521 |
</tr>
|
@@ -1524,7 +1579,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1524 |
<label title="Add custom image on the top of admin content." for="agca_header_logo_custom">Custom header image</label>
|
1525 |
</th>
|
1526 |
<td>
|
1527 |
-
<input title="If this field is not empty, image from provided url will be visible in header" type="text" size="47" id="agca_header_logo_custom" name="agca_header_logo_custom" value="<?php echo get_option('agca_header_logo_custom'); ?>" /><input type="button" onClick="jQuery('#agca_header_logo_custom').val('');" value="Clear" />
|
1528 |
<p><i>Add custom header image</i>.</p>
|
1529 |
</td>
|
1530 |
</tr>
|
@@ -1887,27 +1942,25 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1887 |
</table>
|
1888 |
</div>
|
1889 |
<div id="section_login_page" style="display:none" class="ag_section">
|
1890 |
-
<h2 class="section_title" tabindex="-1">Login Page Settings</h2>
|
1891 |
-
<
|
1892 |
-
|
1893 |
-
<tr valign="center"
|
|
|
|
|
|
|
|
|
|
|
1894 |
<td>
|
1895 |
-
<label for="agca_login_banner"
|
1896 |
</td>
|
1897 |
<td>
|
1898 |
-
<input type="checkbox" name="agca_login_banner" title="
|
1899 |
</td>
|
1900 |
-
</tr>
|
1901 |
-
<tr valign="center">
|
1902 |
-
<td colspan="2">
|
1903 |
-
<div class="ag_table_heading"><h3 tabindex="0">Login Page Options</h3></div>
|
1904 |
-
</td>
|
1905 |
-
<td>
|
1906 |
-
</td>
|
1907 |
</tr>
|
1908 |
<tr valign="center">
|
1909 |
<th scope="row">
|
1910 |
-
<label title="Changes '<- Back to ...' text in top bar on Login page" for="agca_login_banner_text"
|
1911 |
</th>
|
1912 |
<td>
|
1913 |
<textarea title="Changes 'Back to ...' text in top bar on Login page" rows="5" name="agca_login_banner_text" cols="40"><?php echo htmlspecialchars(get_option('agca_login_banner_text')); ?></textarea> <p><i>You should surround it with anchor tag <a></a>.</i></p>
|
@@ -1918,7 +1971,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1918 |
<label title="If this field is not empty, image from provided url will be visible on Login page" for="agca_login_photo_url">Change Login header image</label>
|
1919 |
</th>
|
1920 |
<td>
|
1921 |
-
<input title="If this field is not empty, image from provided url will be visible on Login page" type="text" size="47" id="agca_login_photo_url" name="agca_login_photo_url" value="<?php echo get_option('agca_login_photo_url'); ?>" /><input type="button" onClick="jQuery('#agca_login_photo_url').val('');" value="Clear" />
|
1922 |
<p><i>Put here link of new login image. Image can be of any size and type</i>.</p>
|
1923 |
</td>
|
1924 |
</tr>
|
@@ -1927,7 +1980,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1927 |
<label title="Put here custom link to a web location, that will be triggered on image click" for="agca_login_photo_href">Change hyperlink on Login image</label>
|
1928 |
</th>
|
1929 |
<td>
|
1930 |
-
<input title="Put here custom link to a web location, that will be triggered on image click" type="text" size="47" id="agca_login_photo_href" name="agca_login_photo_href" value="<?php echo get_option('agca_login_photo_href'); ?>" /><input type="button" onClick="jQuery('#agca_login_photo_href').val('');" value="Clear" />
|
1931 |
<p><i>For blog URL use %BLOG%</i></p>
|
1932 |
</td>
|
1933 |
</tr>
|
@@ -1976,7 +2029,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
1976 |
<label title="Change register link on login page to point to your custom registration page." for="agca_login_register_href">Change register hyperlink</label>
|
1977 |
</th>
|
1978 |
<td>
|
1979 |
-
<input title="Change register link on login page to point to your custom registration page." type="text" size="47" id="agca_login_register_href" name="agca_login_register_href" value="<?php echo get_option('agca_login_register_href'); ?>" /><input type="button" onClick="jQuery('#agca_login_register_href').val('');" value="Clear" />
|
1980 |
</td>
|
1981 |
</tr>
|
1982 |
<tr valign="center">
|
@@ -2017,7 +2070,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2017 |
<tr>
|
2018 |
<td colspan="2">
|
2019 |
Reset to default values
|
2020 |
-
<input type="button" id="ag_edit_adminmenu_reset_button" title="Reset menu settings to default values" name="ag_edit_adminmenu_reset_button" value="Reset Settings" /><br />
|
2021 |
<p tabindex="0"><em>(click on menu link to show/hide its submenus below it)</em></p>
|
2022 |
<table id="ag_edit_adminmenu">
|
2023 |
<tr style="background-color:#999;">
|
@@ -2094,7 +2147,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2094 |
<label title="Adds custom logo above the admin menu" for="agca_admin_menu_brand">Add custom branding logo above the admin menu</label>
|
2095 |
</th>
|
2096 |
<td>
|
2097 |
-
<input title="Adds custom logo above the admin menu" type="text" size="47" name="agca_admin_menu_brand" value="<?php echo get_option('agca_admin_menu_brand'); ?>" />
|
2098 |
<p><i>Put here URL of custom branding logo image. Image can be of any size and type</i>.</p>
|
2099 |
</td>
|
2100 |
</tr>
|
@@ -2103,7 +2156,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2103 |
<label title="Change branding logo link.</br></br>Use:</br><strong>%BLOG%</strong> - for blog URL" for="agca_admin_menu_brand_link">Change branding logo link.</label>
|
2104 |
</th>
|
2105 |
<td>
|
2106 |
-
<input id="agca_admin_menu_brand_link" type="text" size="47" name="agca_admin_menu_brand_link" value="<?php echo get_option('agca_admin_menu_brand_link'); ?>" /><input type="button"
|
2107 |
<p><i>Put here a link for branding logo</i>.</p>
|
2108 |
</td>
|
2109 |
</tr>
|
@@ -2128,7 +2181,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2128 |
<option value="_parent">parent</option>
|
2129 |
<option value="_top">top</option>
|
2130 |
</select>
|
2131 |
-
<input type="button" id="ag_add_adminmenu_button" title="Add new item button" name="ag_add_adminmenu_button" value="Add new item" />
|
2132 |
</td><td></td>
|
2133 |
</tr>
|
2134 |
</table>
|
@@ -2157,22 +2210,22 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2157 |
<tr valign="center">
|
2158 |
<th><label title="Change admin page background color" for="color_background">Background color:</label></th>
|
2159 |
<td><input type="text" id="color_background" name="color_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_background']); ?>" />
|
2160 |
-
<input type="button" alt="color_background" class="pick_color_button" value="Pick color" />
|
2161 |
-
<input type="button" alt="color_background" class="pick_color_button_clear" value="Clear" />
|
2162 |
</td>
|
2163 |
-
</tr>
|
2164 |
-
|
2165 |
-
<th><label title="Change
|
2166 |
-
<td><input type="text" id="
|
2167 |
-
<input type="button" alt="
|
2168 |
-
<input type="button" alt="
|
2169 |
</td>
|
2170 |
</tr>
|
2171 |
<tr valign="center">
|
2172 |
<th><label title="Change admin bar (on top) color in admin panel" for="color_header">Admin bar color:</label></th>
|
2173 |
<td><input type="text" id="color_header" name="color_header" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_header']); ?>" />
|
2174 |
-
<input type="button" alt="color_header" class="pick_color_button" value="Pick color" />
|
2175 |
-
<input type="button" alt="color_header" class="pick_color_button_clear" value="Clear" />
|
2176 |
</td>
|
2177 |
</tr>
|
2178 |
<tr valign="center">
|
@@ -2185,79 +2238,79 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2185 |
<tr valign="center">
|
2186 |
<th><label title="Change button background color" for="color_admin_menu_top_button_background">Button background color:</label></th>
|
2187 |
<td><input type="text" id="color_admin_menu_top_button_background" name="color_admin_menu_top_button_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_top_button_background']); ?>" />
|
2188 |
-
<input type="button" alt="color_admin_menu_top_button_background" class="pick_color_button" value="Pick color" />
|
2189 |
-
<input type="button" alt="color_admin_menu_top_button_background" class="pick_color_button_clear" value="Clear" />
|
2190 |
</td>
|
2191 |
</tr>
|
2192 |
<tr valign="center">
|
2193 |
<th><label title="Change button text color" for="color_admin_menu_font">Button text color:</label></th>
|
2194 |
<td><input type="text" id="color_admin_menu_font" name="color_admin_menu_font" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_font']); ?>" />
|
2195 |
-
<input type="button" alt="color_admin_menu_font" class="pick_color_button" value="Pick color" />
|
2196 |
-
<input type="button" alt="color_admin_menu_font" class="pick_color_button_clear" value="Clear" />
|
2197 |
</td>
|
2198 |
</tr>
|
2199 |
<tr valign="center">
|
2200 |
<th><label title="Change button background color for current button" for="color_admin_menu_top_button_current_background">Button current background color:</label></th>
|
2201 |
<td><input type="text" id="color_admin_menu_top_button_current_background" name="color_admin_menu_top_button_current_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_top_button_current_background']); ?>" />
|
2202 |
-
<input type="button" alt="color_admin_menu_top_button_current_background" class="pick_color_button" value="Pick color" />
|
2203 |
-
<input type="button" alt="color_admin_menu_top_button_current_background" class="pick_color_button_clear" value="Clear" />
|
2204 |
</td>
|
2205 |
</tr>
|
2206 |
<tr valign="center">
|
2207 |
<th><label title="Change button background color on mouseover" for="color_admin_menu_top_button_hover_background">Button hover background color:</label></th>
|
2208 |
<td><input type="text" id="color_admin_menu_top_button_hover_background" name="color_admin_menu_top_button_hover_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_top_button_hover_background']); ?>" />
|
2209 |
-
<input type="button" alt="color_admin_menu_top_button_hover_background" class="pick_color_button" value="Pick color" />
|
2210 |
-
<input type="button" alt="color_admin_menu_top_button_hover_background" class="pick_color_button_clear" value="Clear" />
|
2211 |
</td>
|
2212 |
</tr>
|
2213 |
<tr valign="center">
|
2214 |
<th><label title="Change button top border color" for="color_admin_menu_submenu_border_top">Button border top color:</label></th>
|
2215 |
<td><input type="text" id="color_admin_menu_submenu_border_top" name="color_admin_menu_submenu_border_top" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_border_top']); ?>" />
|
2216 |
-
<input type="button" alt="color_admin_menu_submenu_border_top" class="pick_color_button" value="Pick color" />
|
2217 |
-
<input type="button" alt="color_admin_menu_submenu_border_top" class="pick_color_button_clear" value="Clear" />
|
2218 |
</td>
|
2219 |
</tr>
|
2220 |
<tr valign="center">
|
2221 |
<th><label title="Change button bottom border color" for="color_admin_menu_submenu_border_bottom">Button border bottom color:</label></th>
|
2222 |
<td><input type="text" id="color_admin_menu_submenu_border_bottom" name="color_admin_menu_submenu_border_bottom" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_border_bottom']); ?>" />
|
2223 |
-
<input type="button" alt="color_admin_menu_submenu_border_bottom" class="pick_color_button" value="Pick color" />
|
2224 |
-
<input type="button" alt="color_admin_menu_submenu_border_bottom" class="pick_color_button_clear" value="Clear" />
|
2225 |
</td>
|
2226 |
</tr>
|
2227 |
<tr valign="center">
|
2228 |
<th><label title="Change submenu item background color" for="color_admin_menu_submenu_background">Submenu button background color:</label></th>
|
2229 |
<td><input type="text" id="color_admin_menu_submenu_background" name="color_admin_menu_submenu_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_background']); ?>" />
|
2230 |
-
<input type="button" alt="color_admin_menu_submenu_background" class="pick_color_button" value="Pick color" />
|
2231 |
-
<input type="button" alt="color_admin_menu_submenu_background" class="pick_color_button_clear" value="Clear" />
|
2232 |
</td>
|
2233 |
</tr>
|
2234 |
<tr valign="center">
|
2235 |
<th><label title="Change submenu item background color on mouseover" for="color_admin_menu_submenu_background_hover">Submenu button hover background color:</label></th>
|
2236 |
<td><input type="text" id="color_admin_menu_submenu_background_hover" name="color_admin_menu_submenu_background_hover" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_background_hover']); ?>" />
|
2237 |
-
<input type="button" alt="color_admin_menu_submenu_background_hover" class="pick_color_button" value="Pick color" />
|
2238 |
-
<input type="button" alt="color_admin_menu_submenu_background_hover" class="pick_color_button_clear" value="Clear" />
|
2239 |
</td>
|
2240 |
</tr>
|
2241 |
<tr valign="center">
|
2242 |
<th><label title="Change submenu item text color" for="color_admin_submenu_font">Submenu text color:</label></th>
|
2243 |
<td><input type="text" id="color_admin_submenu_font" name="color_admin_submenu_font" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_submenu_font']); ?>" />
|
2244 |
-
<input type="button" alt="color_admin_submenu_font" class="pick_color_button" value="Pick color" />
|
2245 |
-
<input type="button" alt="color_admin_submenu_font" class="pick_color_button_clear" value="Clear" />
|
2246 |
</td>
|
2247 |
</tr>
|
2248 |
<?php if($wpversion >= 3.2) { ?>
|
2249 |
<tr valign="center">
|
2250 |
<th><label title="Change background color of element behind admin menu" for="color_admin_menu_behind_background">Wrapper background color:</label></th>
|
2251 |
<td><input type="text" id="color_admin_menu_behind_background" name="color_admin_menu_behind_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_behind_background']); ?>" />
|
2252 |
-
<input type="button" alt="color_admin_menu_behind_background" class="pick_color_button" value="Pick color" />
|
2253 |
-
<input type="button" alt="color_admin_menu_behind_background" class="pick_color_button_clear" value="Clear" />
|
2254 |
</td>
|
2255 |
</tr>
|
2256 |
<tr valign="center">
|
2257 |
<th><label title="Change border color of element behind admin menu" for="color_admin_menu_behind_border">Wrapper border color:</label></th>
|
2258 |
<td><input type="text" id="color_admin_menu_behind_border" name="color_admin_menu_behind_border" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_behind_border']); ?>" />
|
2259 |
-
<input type="button" alt="color_admin_menu_behind_border" class="pick_color_button" value="Pick color" />
|
2260 |
-
<input type="button" alt="color_admin_menu_behind_border" class="pick_color_button_clear" value="Clear" />
|
2261 |
</td>
|
2262 |
</tr>
|
2263 |
<?php } ?>
|
@@ -2277,22 +2330,22 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2277 |
<tr valign="center">
|
2278 |
<th><label title="Change color in content text" for="color_font_content">Content text color:</label></th>
|
2279 |
<td><input type="text" id="color_font_content" name="color_font_content" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_font_content']); ?>" />
|
2280 |
-
<input type="button" alt="color_font_content" class="pick_color_button" value="Pick color" />
|
2281 |
-
<input type="button" alt="color_font_content" class="pick_color_button_clear" value="Clear" />
|
2282 |
</td>
|
2283 |
</tr>
|
2284 |
<tr valign="center">
|
2285 |
<th><label title="Change color of admin bar text" for="color_font_header">Admin bar text color:</label></th>
|
2286 |
<td><input type="text" id="color_font_header" name="color_font_header" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_font_header']); ?>" />
|
2287 |
-
<input type="button" alt="color_font_header" class="pick_color_button" value="Pick color" />
|
2288 |
-
<input type="button" alt="color_font_header" class="pick_color_button_clear" value="Clear" />
|
2289 |
</td>
|
2290 |
</tr>
|
2291 |
<tr valign="center">
|
2292 |
<th><label title="Change color in fotter text" for="color_font_footer">Footer text color:</label></th>
|
2293 |
<td><input type="text" id="color_font_footer" name="color_font_footer" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_font_footer']); ?>" />
|
2294 |
-
<input type="button" alt="color_font_footer" class="pick_color_button" value="Pick color" />
|
2295 |
-
<input type="button" alt="color_font_footer" class="pick_color_button_clear" value="Clear" />
|
2296 |
</td>
|
2297 |
</tr>
|
2298 |
<tr valign="center">
|
@@ -2305,15 +2358,15 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2305 |
<tr valign="center">
|
2306 |
<th><label title="Change color in header text" for="color_widget_bar">Title bar background color:</label></th>
|
2307 |
<td><input type="text" id="color_widget_bar" name="color_widget_bar" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_widget_bar']); ?>" />
|
2308 |
-
<input type="button" alt="color_widget_bar" class="pick_color_button" value="Pick color" />
|
2309 |
-
<input type="button" alt="color_widget_bar" class="pick_color_button_clear" value="Clear" />
|
2310 |
</td>
|
2311 |
</tr>
|
2312 |
<tr valign="center">
|
2313 |
<th><label title="Change widget background color" for="color_widget_background">Background color:</label></th>
|
2314 |
<td><input type="text" id="color_widget_background" name="color_widget_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_widget_background']); ?>" />
|
2315 |
-
<input type="button" alt="color_widget_background" class="pick_color_button" value="Pick color" />
|
2316 |
-
<input type="button" alt="color_widget_background" class="pick_color_button_clear" value="Clear" />
|
2317 |
</td>
|
2318 |
</tr>
|
2319 |
</table>
|
@@ -2364,11 +2417,11 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2364 |
</th>
|
2365 |
<td id="import_file_area">
|
2366 |
<div id="export_settings_additional" style="display: none" ><input type="checkbox" id="export_settings_include_admin_menu" name="export_settings_include_admin_menu" /> <label title="Includes 'Admin Menu' configuration in exported settings.</br>Include admin menu settings only if your admin menu looks the same on multiple sites.</br>If configurations are different, imported menu settings could be wrong. In that case, use 'Reset Settings' button from 'Admin Menu' section.</br>(Custom buttons and menu configuration will be included anyway)">Include Admin Menu(?)</label></div>
|
2367 |
-
<input type="button" name="agca_export_settings" value="Export Settings" onclick="exportSettings();"/></br>
|
2368 |
<input type="file" id="settings_import_file" name="settings_import_file" style="display: none"/>
|
2369 |
<input type="hidden" id="_agca_import_settings" name="_agca_import_settings" value="false" />
|
2370 |
<input type="hidden" id="_agca_export_settings" name="_agca_export_settings" value="false" />
|
2371 |
-
<input type="button" name="agca_import_settings" value="Import Settings" onclick="importSettings();"/>
|
2372 |
</td>
|
2373 |
|
2374 |
|
@@ -2387,7 +2440,7 @@ jQuery('#ag_add_adminmenu').append(buttonsJq);
|
|
2387 |
</div>
|
2388 |
|
2389 |
<br />
|
2390 |
-
<br /><br /><br /><p id="agca_footer_support_info">WordPress 'AG Custom Admin' plugin by Argonius. If you have any questions, ideas for future development or if you found a bug or having any issues regarding this plugin, please visit plugin's <a href="http://
|
2391 |
<?php
|
2392 |
}
|
2393 |
}
|
1 |
<?php
|
2 |
/*
|
3 |
Plugin Name: AG Custom Admin
|
4 |
+
Plugin URI: http://agca.argonius.com/ag-custom-admin/category/ag_custom_admin
|
5 |
Description: Hide or change items in admin panel. Customize buttons from admin menu. Colorize admin and login page with custom colors.
|
6 |
Author: Argonius
|
7 |
+
Version: 1.2.7
|
8 |
+
Author URI: http://www.argonius.com/
|
9 |
|
10 |
Copyright 2011. Argonius (email : info@argonius.com)
|
11 |
|
27 |
//fb($_POST);
|
28 |
|
29 |
$agca = new AGCA();
|
30 |
+
|
31 |
class AGCA{
|
32 |
private $colorizer="";
|
33 |
private $active_plugin;
|
36 |
private $context = "";
|
37 |
private $saveAfterImport = false;
|
38 |
public function __construct()
|
39 |
+
{
|
40 |
+
|
41 |
+
$this->reloadScript();
|
42 |
+
|
43 |
add_filter('plugin_row_meta', array(&$this,'jk_filter_plugin_links'), 10, 2);
|
44 |
add_action('admin_init', array(&$this,'agca_register_settings'));
|
45 |
add_action('admin_head', array(&$this,'print_admin_css'));
|
46 |
add_action('login_head', array(&$this,'print_login_head'));
|
47 |
add_action('admin_menu', array(&$this,'agca_create_menu'));
|
48 |
add_action('wp_head', array(&$this,'print_page'));
|
49 |
+
register_deactivation_hook(__FILE__, array(&$this,'agca_deactivate'));
|
|
|
50 |
|
51 |
|
52 |
/*Initialize properties*/
|
53 |
$this->colorizer = $this->jsonMenuArray(get_option('ag_colorizer_json'),'colorizer');
|
54 |
//fb($this->colorizer);
|
55 |
+
$this->agca_version = "1.2.7";
|
56 |
}
|
57 |
// Add donate and support information
|
58 |
function jk_filter_plugin_links($links, $file)
|
60 |
if ( $file == plugin_basename(__FILE__) )
|
61 |
{
|
62 |
$links[] = '<a href="tools.php?page=ag-custom-admin/plugin.php">' . __('Settings') . '</a>';
|
63 |
+
$links[] = '<a href="http://agca.argonius.com/ag-custom-admin/category/ag_custom_admin">' . __('Support') . '</a>';
|
64 |
+
$links[] = '<a href="http://agca.argonius.com/ag-custom-admin/support-for-future-development">' . __('Donate') . '</a>';
|
65 |
}
|
66 |
return $links;
|
67 |
}
|
108 |
}
|
109 |
|
110 |
function reloadScript(){
|
111 |
+
if(in_array($GLOBALS['pagenow'], array('wp-login.php', 'wp-register.php')) || WP_ADMIN == 1){
|
112 |
+
wp_enqueue_script('jquery');
|
113 |
+
}
|
114 |
}
|
115 |
|
116 |
function agca_register_settings() {
|
418 |
|
419 |
function agca_create_admin_button($name,$arr) {
|
420 |
$class="";
|
421 |
+
$wpversion = $this->get_wp_version();
|
422 |
$href = $arr["value"];
|
423 |
$target =$arr["target"];;
|
424 |
if($name == 'AG Custom Admin'){
|
426 |
$target = "_self";
|
427 |
$href = $arr;
|
428 |
}
|
429 |
+
$button ="";
|
430 |
+
|
431 |
+
if($wpversion >=3.5 ){
|
432 |
+
$button .= '<li id="menu-'.$name.'" class="ag-custom-button wp-not-current-submenu menu-top">';
|
433 |
+
$button .= '<a target="'.$target.'" class="wp-has-submenu wp-not-current-submenu menu-top" href="'.$href.'">';
|
434 |
+
$button .= '<div style="padding-left:5px;" class="wp-menu-name">'.$name.'</div>';
|
435 |
+
$button .= '</a>';
|
436 |
+
$button .= '</li>';
|
437 |
+
}else{
|
438 |
+
$button .= '<li id="menu-'.$name.'" class="ag-custom-button menu-top menu-top-first '.$class.' menu-top-last">';
|
439 |
$button .= '<div class="wp-menu-toggle" style="display: none;"><br></div>';
|
440 |
$button .= '<a tabindex="1" target="'.$target.'" class="menu-top menu-top-last" href="'.$href.'">'.$name.'</a>';
|
441 |
+
$button .= '</li>';
|
442 |
+
}
|
443 |
|
444 |
return $button;
|
445 |
}
|
544 |
//only output the script once..
|
545 |
jQueryScriptOutputted = true;
|
546 |
//output the script (load it from google api)
|
547 |
+
document.write("<scr" + "ipt type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js\"></scr" + "ipt>");
|
548 |
}
|
549 |
setTimeout("initJQuery()", 50);
|
550 |
} else {
|
743 |
|
744 |
<?php } ?>
|
745 |
<?php if(get_option('agca_howdy')!=""){ ?>
|
746 |
+
if(isWPHigherOrEqualThan("3.5")){
|
747 |
+
var alltext="";
|
748 |
+
alltext="";
|
749 |
+
jQuery('li#wp-admin-bar-my-account').css('cursor','default');
|
750 |
+
alltext = jQuery('li#wp-admin-bar-my-account').html();
|
751 |
+
if(alltext!=null){
|
752 |
+
var parts = alltext.split(',');
|
753 |
+
alltext = "<?php echo get_option('agca_howdy'); ?>" + ", " + parts[1];
|
754 |
+
}
|
755 |
+
jQuery("li#wp-admin-bar-my-account").html("<a href=\"#\">"+alltext+"</a>");
|
756 |
+
}else if(isWPHigherOrEqualThan("3.3")){
|
757 |
var alltext="";
|
758 |
alltext="";
|
759 |
jQuery('li#wp-admin-bar-my-account').css('cursor','default');
|
778 |
if(howdyText !=null){
|
779 |
jQuery("#user_info").html("<p>"+"<?php echo get_option('agca_howdy'); ?>"+howdyText.substr(9));
|
780 |
}
|
781 |
+
}
|
782 |
+
if(isWPHigherOrEqualThan("3.5")){
|
783 |
+
//jQuery("#wp-admin-bar-my-account").css("padding-left","10px");
|
784 |
+
//jQuery("#wp-admin-bar-my-account").css("padding-right","10px");
|
785 |
+
//jQuery("#wp-admin-bar-my-account img").css({"margin-left":"5px","margin-bottom":"-4px"});
|
786 |
+
|
787 |
+
}
|
788 |
+
|
789 |
<?php } ?>
|
790 |
<?php if(get_option('agca_logout')!=""){ ?>
|
791 |
if(isWPHigherOrEqualThan("3.3")){
|
908 |
var errors = false;
|
909 |
var isSettingsImport = false;
|
910 |
var agca_context = "admin";
|
911 |
+
var roundedSidberSize = 0;
|
912 |
|
913 |
<?php
|
914 |
if(isset($_POST['_agca_import_settings']) && $_POST['_agca_import_settings']=='true'){
|
952 |
<?php $buttonsJq = $this->jsonMenuArray(get_option('ag_add_adminmenu_json'),'buttonsJq'); ?>
|
953 |
var buttonsJq = '<?php echo $buttonsJq; ?>';
|
954 |
|
955 |
+
<?php if($wpversion >=3.5 ){ ?>
|
956 |
+
createEditMenuPageV35(checkboxes,textboxes);
|
957 |
+
<?php }else if($wpversion >=3.2 ){ ?>
|
958 |
createEditMenuPageV32(checkboxes,textboxes);
|
959 |
<?php }else{ ?>
|
960 |
createEditMenuPage(checkboxes,textboxes);
|
961 |
<?php } ?>
|
962 |
+
//console.log(checkboxes);
|
963 |
+
// console.log(textboxes);
|
964 |
|
965 |
<?php
|
966 |
//if admin, and option to hide settings for admin is set
|
991 |
<?php } ?>
|
992 |
|
993 |
<?php if(get_option('agca_admin_menu_submenu_round')==true){ ?>
|
994 |
+
jQuery("#adminmenu .wp-submenu").css("border-radius","<?php echo get_option('agca_admin_menu_submenu_round_size'); ?>px");
|
995 |
+
roundedSidberSize = <?php echo get_option('agca_admin_menu_submenu_round_size'); ?>;
|
996 |
+
|
997 |
+
|
998 |
<?php } ?>
|
999 |
|
1000 |
<?php $this->print_admin_bar_scripts(); ?>
|
1031 |
<?php } ?>
|
1032 |
|
1033 |
<?php if(get_option('agca_footer')==true){ ?>
|
1034 |
+
jQuery("#footer,#wpfooter").css("display","none");
|
1035 |
<?php } ?>
|
1036 |
|
1037 |
|
1146 |
|
1147 |
<?php /*If Turned on*/ ?>
|
1148 |
|
1149 |
+
|
|
|
|
|
|
|
1150 |
|
1151 |
<?php if(get_option('agca_admin_menu_agca_button_only') == true){ ?>
|
1152 |
jQuery('#adminmenu > li').each(function(){
|
1154 |
jQuery(this).addClass('noclass');
|
1155 |
}
|
1156 |
});
|
1157 |
+
<?php } ?>
|
1158 |
+
|
1159 |
+
<?php /*Only admin see button*/
|
1160 |
+
if (current_user_can($this->admin_capability())){ ?>
|
1161 |
+
jQuery('#adminmenu').append('<?php echo $this->agca_create_admin_button('AG Custom Admin','tools.php?page=ag-custom-admin/plugin.php'); ?>');
|
1162 |
+
<?php } ?>
|
1163 |
|
1164 |
<?php /*EDIT MENU ITEMS*/?>
|
1165 |
<?php if(get_option('ag_edit_adminmenu_json')!=""){
|
1188 |
if(checkboxes[i][0].indexOf("<-TOP->") >=0){ //if it is top item
|
1189 |
if(checkboxes[i][0].indexOf(topmenuitem) >0){//if found match in menu, with top item in array
|
1190 |
matchFound = true;
|
1191 |
+
//console.log(checkboxes[i][0]);
|
1192 |
+
//console.log(jQuery(this).find('.wp-menu-name').text());
|
1193 |
+
|
1194 |
+
<?php if($wpversion >=3.5 ){ ?>
|
1195 |
+
jQuery(this).find('.wp-menu-name').html(textboxes[i][1]);
|
1196 |
+
<?php }else{ ?>
|
1197 |
+
jQuery(this).find('a').eq(1).html(textboxes[i][1]);
|
1198 |
+
<?php } ?>
|
1199 |
+
|
1200 |
if((checkboxes[i][1] == "true") || (checkboxes[i][1] == "checked")){
|
1201 |
jQuery(this).addClass('noclass');
|
1202 |
}
|
1205 |
var selector = '#' + topmenuitem + ' ul li';
|
1206 |
//console.log(i+" "+checkboxes);
|
1207 |
while((i<checkboxes.length) && (checkboxes[i][0].indexOf("<-TOP->") < 0)){
|
1208 |
+
jQuery(selector).each(function(){ //loop through all submenus
|
1209 |
+
var currentItemText = "";
|
1210 |
+
|
1211 |
+
<?php if($wpversion >=3.5 ){ ?>
|
1212 |
+
currentItemText = jQuery(this).clone();
|
1213 |
+
jQuery(currentItemText).find("span").remove();
|
1214 |
+
currentItemText = currentItemText.text();
|
1215 |
+
<?php }else{ ?>
|
1216 |
+
currentItemText = jQuery(this).text();
|
1217 |
+
<?php } ?>
|
1218 |
+
|
1219 |
+
//console.log("*"+checkboxes[i][0]+":"+withoutNumber+"*");
|
1220 |
+
if(checkboxes[i][0] == currentItemText){
|
1221 |
+
|
1222 |
if((checkboxes[i][1] == "true") || (checkboxes[i][1] == "checked")){
|
1223 |
jQuery(this).addClass('noclass');
|
1224 |
}
|
1287 |
$this->updateAllColors();
|
1288 |
}else{
|
1289 |
?>function updateAllColors(){}; <?php
|
1290 |
+
} ?>
|
1291 |
|
1292 |
|
1293 |
/* ]]> */
|
1310 |
}
|
1311 |
|
1312 |
function print_login_head(){
|
1313 |
+
$this->context = "login";
|
|
|
|
|
|
|
1314 |
$this->agca_get_includes();
|
1315 |
$wpversion = $this->get_wp_version();
|
1316 |
?>
|
1398 |
jQuery('label,h1,h2,h3,h4,h5,h6,a,p,.form-table th,.form-wrap label').css('text-shadow','none');
|
1399 |
|
1400 |
if(isWPHigherOrEqualThan("3.3")){
|
1401 |
+
jQuery("body.login").css("background","<?php echo $this->colorizer['login_color_background'];?>");
|
1402 |
}else{
|
1403 |
|
1404 |
<?php
|
1405 |
+
if($this->colorizer['login_color_background']!=""){
|
1406 |
?>
|
1407 |
+
updateTargetColor("login_color_background","<?php echo $this->colorizer['login_color_background'];?>");
|
1408 |
|
1409 |
<?php
|
1410 |
}
|
1466 |
<form method="post" id="agca_form" action="options.php">
|
1467 |
<?php settings_fields( 'agca-options-group' ); ?>
|
1468 |
<table>
|
1469 |
+
<tr valign="left" >
|
1470 |
<th scope="row">
|
1471 |
+
<label title="If checked, all users will be affected with these changes, except admin. Not checked = apply for all</br></br><strong>Q</strong>: Who is administrator?</br><strong>A</strong>: Go to <i>Advanced</i> tab and change capability option to define admin users." for="agca_role_allbutadmin">Do not apply these settings for Admin </label>
|
1472 |
</th>
|
1473 |
<td><input title="If checked, all users will be affected with these changes, except admin. Not checked = apply for all" type="checkbox" name="agca_role_allbutadmin" value="true" <?php if (get_option('agca_role_allbutadmin')==true) echo 'checked="checked" '; echo get_option('agca_role_allbutadmin'); ?> />
|
1474 |
</td>
|
1475 |
+
</tr>
|
1476 |
+
</table>
|
1477 |
+
<div style="float:right;width:152px;margin-left: 100px;margin-top: -25px;"><strong><span style="font-size:12px" >Your feedback:</span></strong> <a class="feedback positive" target="_blank" title="POSITIVE FEEDBACK: I like this plugin!" href="http://agca.argonius.com/ag-custom-admin/feedback/ag-custom-admin-positive-feedback?comments=hidden" style="padding:5px;"><img style="" width="15" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>images/thumbup.png" /></a> <a class="feedback" target="_blank" title="NEGATIVE FEEDBACK: I don't like this plugin." style="padding:5px;" href="http://agca.argonius.com/ag-custom-admin/feedback/ag-custom-admin-negative-feedback?comments=hidden"><img width="15" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>images/thumbdown.png" /></a></div>
|
1478 |
+
|
1479 |
<br />
|
1480 |
<ul id="ag_main_menu">
|
1481 |
<li class="selected"><a href="#admin-bar-settings" title="Settings for admin bar" >Admin Bar</a></li>
|
1485 |
<li class="normal" ><a href="#admin-menu-settings" title="Settings for main admin menu">Admin Menu</a></li>
|
1486 |
<li class="normal"><a href="#ag-colorizer-setttings" title="AG colorizer settings">Colorizer</a></li>
|
1487 |
<li class="normal"><a href="#ag-advanced" title="My custom scripts">Advanced</a></li>
|
1488 |
+
<li style="background:none;border:none;padding:0;"><a id="agca_donate_button" target="_blank" style="margin-left:8px" title="Like this plugin? You can support its future development by giving a donation by your wish " href="http://agca.argonius.com/ag-custom-admin/support-for-future-development"><img alt="Donate" src="<?php echo trailingslashit(plugins_url(basename(dirname(__FILE__)))); ?>images/btn_donate_LG.gif" /></a>
|
1489 |
+
</li>
|
1490 |
<li style="background:none;border:none;padding:0;padding-left:10px;margin-top:-7px"></li>
|
1491 |
</ul>
|
1492 |
<div id="agca_advertising">
|
1524 |
<input type="checkbox" title='Check this if you want to show Log Out button in top right corner of admin page' name="agca_header_show_logout" value="true" <?php if ((get_option('agca_header')==true) && (get_option('agca_header_show_logout')==true)) echo 'checked="checked" '; ?> />
|
1525 |
</td>
|
1526 |
</tr>
|
1527 |
+
<tr valign="center" >
|
1528 |
+
<td>
|
1529 |
+
<label tabindex="0" title="Removes admin bar customizations (AGCA scripts) on front end." for="agca_admin_bar_frontend">Remove admin bar customizations on site pages</label>
|
1530 |
+
</td>
|
1531 |
+
<td>
|
1532 |
+
<input style="margin-left:-5px" id="agca_admin_bar_frontend" type="checkbox" title="Removes admin bar customizations (AGCA scripts) on front end." name="agca_admin_bar_frontend" value="true" <?php if (get_option('agca_admin_bar_frontend')==true) echo 'checked="checked" '; ?> />
|
1533 |
+
</td>
|
1534 |
+
</tr>
|
1535 |
+
<tr valign="center" >
|
1536 |
+
<td>
|
1537 |
+
<label tabindex="0" title="Removes admin bar on front end." for="agca_admin_bar_frontend_hide">Remove admin bar on site pages</label>
|
1538 |
+
</td>
|
1539 |
+
<td>
|
1540 |
+
<input style="margin-left:-5px" id="agca_admin_bar_frontend_hide" type="checkbox" title="Removes admin bar on front end." name="agca_admin_bar_frontend_hide" value="true" <?php if (get_option('agca_admin_bar_frontend_hide')==true) echo 'checked="checked" '; ?> />
|
1541 |
+
</td>
|
1542 |
+
</tr>
|
1543 |
<tr valign="center">
|
1544 |
<td colspan="2">
|
1545 |
<div class="ag_table_heading"><h3 tabindex="0">Elements on Left</h3></div>
|
1555 |
<input type="checkbox" title="This is link next to heading in admin bar" name="agca_privacy_options" value="true" <?php if (get_option('agca_privacy_options')==true) echo 'checked="checked" '; ?> />
|
1556 |
</td>
|
1557 |
</tr>
|
1558 |
+
<?php } ?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1559 |
<tr valign="center">
|
1560 |
<th >
|
1561 |
<label title="Change default WordPress logo with custom image." for="agca_wp_logo_custom">Change admin bar logo</label>
|
1562 |
</th>
|
1563 |
<td>
|
1564 |
+
<input id="agca_wp_logo_custom" title="If this field is not empty, image from provided url will be visible in top bar" type="text" size="47" name="agca_wp_logo_custom" value="<?php echo get_option('agca_wp_logo_custom'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_wp_logo_custom').val('');" value="Clear" />
|
1565 |
<p><i>Put here an URL of the new top bar image ( maximum height = 28px)</i>.</p>
|
1566 |
</td>
|
1567 |
</tr>
|
1570 |
<label title="Change admin bar logo link.</br></br>Use:</br><strong>%BLOG%</strong> - for blog URL</br><strong>%SWITCH%</strong> - to switch betweent admin and site area" for="agca_wp_logo_custom">Change admin bar logo link</label>
|
1571 |
</th>
|
1572 |
<td>
|
1573 |
+
<input id="agca_wp_logo_custom_link" type="text" size="47" name="agca_wp_logo_custom_link" value="<?php echo get_option('agca_wp_logo_custom_link'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_wp_logo_custom_link').val('');" value="Clear" />
|
1574 |
<p><i>Put here a link for admin bar logo </i>.</p>
|
1575 |
</td>
|
1576 |
</tr>
|
1579 |
<label title="Add custom image on the top of admin content." for="agca_header_logo_custom">Custom header image</label>
|
1580 |
</th>
|
1581 |
<td>
|
1582 |
+
<input title="If this field is not empty, image from provided url will be visible in header" type="text" size="47" id="agca_header_logo_custom" name="agca_header_logo_custom" value="<?php echo get_option('agca_header_logo_custom'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_header_logo_custom').val('');" value="Clear" />
|
1583 |
<p><i>Add custom header image</i>.</p>
|
1584 |
</td>
|
1585 |
</tr>
|
1942 |
</table>
|
1943 |
</div>
|
1944 |
<div id="section_login_page" style="display:none" class="ag_section">
|
1945 |
+
<h2 class="section_title" tabindex="-1">Login Page Settings</h2>
|
1946 |
+
<table class="form-table" width="500px">
|
1947 |
+
|
1948 |
+
<tr valign="center">
|
1949 |
+
<td colspan="2">
|
1950 |
+
<div class="ag_table_heading"><h3 tabindex="0">Login Page Options</h3></div>
|
1951 |
+
</td>
|
1952 |
+
</tr>
|
1953 |
+
<tr valign="center">
|
1954 |
<td>
|
1955 |
+
<label for="agca_login_banner">Hide back to blog text</label>
|
1956 |
</td>
|
1957 |
<td>
|
1958 |
+
<input type="checkbox" name="agca_login_banner" title="Hide back to blog block" value="true" <?php if (get_option('agca_login_banner')==true) echo 'checked="checked" '; ?> />
|
1959 |
</td>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1960 |
</tr>
|
1961 |
<tr valign="center">
|
1962 |
<th scope="row">
|
1963 |
+
<label title="Changes '<- Back to ...' text in top bar on Login page" for="agca_login_banner_text">Change back to blog text</label>
|
1964 |
</th>
|
1965 |
<td>
|
1966 |
<textarea title="Changes 'Back to ...' text in top bar on Login page" rows="5" name="agca_login_banner_text" cols="40"><?php echo htmlspecialchars(get_option('agca_login_banner_text')); ?></textarea> <p><i>You should surround it with anchor tag <a></a>.</i></p>
|
1971 |
<label title="If this field is not empty, image from provided url will be visible on Login page" for="agca_login_photo_url">Change Login header image</label>
|
1972 |
</th>
|
1973 |
<td>
|
1974 |
+
<input title="If this field is not empty, image from provided url will be visible on Login page" type="text" size="47" id="agca_login_photo_url" name="agca_login_photo_url" value="<?php echo get_option('agca_login_photo_url'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_login_photo_url').val('');" value="Clear" />
|
1975 |
<p><i>Put here link of new login image. Image can be of any size and type</i>.</p>
|
1976 |
</td>
|
1977 |
</tr>
|
1980 |
<label title="Put here custom link to a web location, that will be triggered on image click" for="agca_login_photo_href">Change hyperlink on Login image</label>
|
1981 |
</th>
|
1982 |
<td>
|
1983 |
+
<input title="Put here custom link to a web location, that will be triggered on image click" type="text" size="47" id="agca_login_photo_href" name="agca_login_photo_href" value="<?php echo get_option('agca_login_photo_href'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_login_photo_href').val('');" value="Clear" />
|
1984 |
<p><i>For blog URL use %BLOG%</i></p>
|
1985 |
</td>
|
1986 |
</tr>
|
2029 |
<label title="Change register link on login page to point to your custom registration page." for="agca_login_register_href">Change register hyperlink</label>
|
2030 |
</th>
|
2031 |
<td>
|
2032 |
+
<input title="Change register link on login page to point to your custom registration page." type="text" size="47" id="agca_login_register_href" name="agca_login_register_href" value="<?php echo get_option('agca_login_register_href'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_login_register_href').val('');" value="Clear" />
|
2033 |
</td>
|
2034 |
</tr>
|
2035 |
<tr valign="center">
|
2070 |
<tr>
|
2071 |
<td colspan="2">
|
2072 |
Reset to default values
|
2073 |
+
<input type="button" class="agca_button" id="ag_edit_adminmenu_reset_button" title="Reset menu settings to default values" name="ag_edit_adminmenu_reset_button" value="Reset Settings" /><br />
|
2074 |
<p tabindex="0"><em>(click on menu link to show/hide its submenus below it)</em></p>
|
2075 |
<table id="ag_edit_adminmenu">
|
2076 |
<tr style="background-color:#999;">
|
2147 |
<label title="Adds custom logo above the admin menu" for="agca_admin_menu_brand">Add custom branding logo above the admin menu</label>
|
2148 |
</th>
|
2149 |
<td>
|
2150 |
+
<input id="agca_admin_menu_brand" title="Adds custom logo above the admin menu" type="text" size="47" name="agca_admin_menu_brand" value="<?php echo get_option('agca_admin_menu_brand'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_admin_menu_brand').val('');" value="Clear" />
|
2151 |
<p><i>Put here URL of custom branding logo image. Image can be of any size and type</i>.</p>
|
2152 |
</td>
|
2153 |
</tr>
|
2156 |
<label title="Change branding logo link.</br></br>Use:</br><strong>%BLOG%</strong> - for blog URL" for="agca_admin_menu_brand_link">Change branding logo link.</label>
|
2157 |
</th>
|
2158 |
<td>
|
2159 |
+
<input id="agca_admin_menu_brand_link" type="text" size="47" name="agca_admin_menu_brand_link" value="<?php echo get_option('agca_admin_menu_brand_link'); ?>" /><input type="button" class="agca_button" onClick="jQuery('#agca_admin_menu_brand_link').val('');" value="Clear" />
|
2160 |
<p><i>Put here a link for branding logo</i>.</p>
|
2161 |
</td>
|
2162 |
</tr>
|
2181 |
<option value="_parent">parent</option>
|
2182 |
<option value="_top">top</option>
|
2183 |
</select>
|
2184 |
+
<input type="button" id="ag_add_adminmenu_button" class="agca_button" title="Add new item button" name="ag_add_adminmenu_button" value="Add new item" />
|
2185 |
</td><td></td>
|
2186 |
</tr>
|
2187 |
</table>
|
2210 |
<tr valign="center">
|
2211 |
<th><label title="Change admin page background color" for="color_background">Background color:</label></th>
|
2212 |
<td><input type="text" id="color_background" name="color_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_background']); ?>" />
|
2213 |
+
<input type="button" alt="color_background" class="pick_color_button agca_button" value="Pick color" />
|
2214 |
+
<input type="button" alt="color_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2215 |
</td>
|
2216 |
+
</tr>
|
2217 |
+
<tr valign="center">
|
2218 |
+
<th><label title="Change login page background color" for="login_color_background">Login page background color:</label></th>
|
2219 |
+
<td><input type="text" id="login_color_background" name="login_color_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['login_color_background']); ?>" />
|
2220 |
+
<input type="button" alt="login_color_background" class="pick_color_button agca_button" value="Pick color" />
|
2221 |
+
<input type="button" alt="login_color_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2222 |
</td>
|
2223 |
</tr>
|
2224 |
<tr valign="center">
|
2225 |
<th><label title="Change admin bar (on top) color in admin panel" for="color_header">Admin bar color:</label></th>
|
2226 |
<td><input type="text" id="color_header" name="color_header" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_header']); ?>" />
|
2227 |
+
<input type="button" alt="color_header" class="pick_color_button agca_button" value="Pick color" />
|
2228 |
+
<input type="button" alt="color_header" class="pick_color_button_clear agca_button" value="Clear" />
|
2229 |
</td>
|
2230 |
</tr>
|
2231 |
<tr valign="center">
|
2238 |
<tr valign="center">
|
2239 |
<th><label title="Change button background color" for="color_admin_menu_top_button_background">Button background color:</label></th>
|
2240 |
<td><input type="text" id="color_admin_menu_top_button_background" name="color_admin_menu_top_button_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_top_button_background']); ?>" />
|
2241 |
+
<input type="button" alt="color_admin_menu_top_button_background" class="pick_color_button agca_button" value="Pick color" />
|
2242 |
+
<input type="button" alt="color_admin_menu_top_button_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2243 |
</td>
|
2244 |
</tr>
|
2245 |
<tr valign="center">
|
2246 |
<th><label title="Change button text color" for="color_admin_menu_font">Button text color:</label></th>
|
2247 |
<td><input type="text" id="color_admin_menu_font" name="color_admin_menu_font" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_font']); ?>" />
|
2248 |
+
<input type="button" alt="color_admin_menu_font" class="pick_color_button agca_button" value="Pick color" />
|
2249 |
+
<input type="button" alt="color_admin_menu_font" class="pick_color_button_clear agca_button" value="Clear" />
|
2250 |
</td>
|
2251 |
</tr>
|
2252 |
<tr valign="center">
|
2253 |
<th><label title="Change button background color for current button" for="color_admin_menu_top_button_current_background">Button current background color:</label></th>
|
2254 |
<td><input type="text" id="color_admin_menu_top_button_current_background" name="color_admin_menu_top_button_current_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_top_button_current_background']); ?>" />
|
2255 |
+
<input type="button" alt="color_admin_menu_top_button_current_background" class="pick_color_button agca_button" value="Pick color" />
|
2256 |
+
<input type="button" alt="color_admin_menu_top_button_current_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2257 |
</td>
|
2258 |
</tr>
|
2259 |
<tr valign="center">
|
2260 |
<th><label title="Change button background color on mouseover" for="color_admin_menu_top_button_hover_background">Button hover background color:</label></th>
|
2261 |
<td><input type="text" id="color_admin_menu_top_button_hover_background" name="color_admin_menu_top_button_hover_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_top_button_hover_background']); ?>" />
|
2262 |
+
<input type="button" alt="color_admin_menu_top_button_hover_background" class="pick_color_button agca_button" value="Pick color" />
|
2263 |
+
<input type="button" alt="color_admin_menu_top_button_hover_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2264 |
</td>
|
2265 |
</tr>
|
2266 |
<tr valign="center">
|
2267 |
<th><label title="Change button top border color" for="color_admin_menu_submenu_border_top">Button border top color:</label></th>
|
2268 |
<td><input type="text" id="color_admin_menu_submenu_border_top" name="color_admin_menu_submenu_border_top" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_border_top']); ?>" />
|
2269 |
+
<input type="button" alt="color_admin_menu_submenu_border_top" class="pick_color_button agca_button" value="Pick color" />
|
2270 |
+
<input type="button" alt="color_admin_menu_submenu_border_top" class="pick_color_button_clear agca_button" value="Clear" />
|
2271 |
</td>
|
2272 |
</tr>
|
2273 |
<tr valign="center">
|
2274 |
<th><label title="Change button bottom border color" for="color_admin_menu_submenu_border_bottom">Button border bottom color:</label></th>
|
2275 |
<td><input type="text" id="color_admin_menu_submenu_border_bottom" name="color_admin_menu_submenu_border_bottom" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_border_bottom']); ?>" />
|
2276 |
+
<input type="button" alt="color_admin_menu_submenu_border_bottom" class="pick_color_button agca_button" value="Pick color" />
|
2277 |
+
<input type="button" alt="color_admin_menu_submenu_border_bottom" class="pick_color_button_clear agca_button" value="Clear" />
|
2278 |
</td>
|
2279 |
</tr>
|
2280 |
<tr valign="center">
|
2281 |
<th><label title="Change submenu item background color" for="color_admin_menu_submenu_background">Submenu button background color:</label></th>
|
2282 |
<td><input type="text" id="color_admin_menu_submenu_background" name="color_admin_menu_submenu_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_background']); ?>" />
|
2283 |
+
<input type="button" alt="color_admin_menu_submenu_background" class="pick_color_button agca_button" value="Pick color" />
|
2284 |
+
<input type="button" alt="color_admin_menu_submenu_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2285 |
</td>
|
2286 |
</tr>
|
2287 |
<tr valign="center">
|
2288 |
<th><label title="Change submenu item background color on mouseover" for="color_admin_menu_submenu_background_hover">Submenu button hover background color:</label></th>
|
2289 |
<td><input type="text" id="color_admin_menu_submenu_background_hover" name="color_admin_menu_submenu_background_hover" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_submenu_background_hover']); ?>" />
|
2290 |
+
<input type="button" alt="color_admin_menu_submenu_background_hover" class="pick_color_button agca_button" value="Pick color" />
|
2291 |
+
<input type="button" alt="color_admin_menu_submenu_background_hover" class="pick_color_button_clear agca_button" value="Clear" />
|
2292 |
</td>
|
2293 |
</tr>
|
2294 |
<tr valign="center">
|
2295 |
<th><label title="Change submenu item text color" for="color_admin_submenu_font">Submenu text color:</label></th>
|
2296 |
<td><input type="text" id="color_admin_submenu_font" name="color_admin_submenu_font" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_submenu_font']); ?>" />
|
2297 |
+
<input type="button" alt="color_admin_submenu_font" class="pick_color_button agca_button" value="Pick color" />
|
2298 |
+
<input type="button" alt="color_admin_submenu_font" class="pick_color_button_clear agca_button" value="Clear" />
|
2299 |
</td>
|
2300 |
</tr>
|
2301 |
<?php if($wpversion >= 3.2) { ?>
|
2302 |
<tr valign="center">
|
2303 |
<th><label title="Change background color of element behind admin menu" for="color_admin_menu_behind_background">Wrapper background color:</label></th>
|
2304 |
<td><input type="text" id="color_admin_menu_behind_background" name="color_admin_menu_behind_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_behind_background']); ?>" />
|
2305 |
+
<input type="button" alt="color_admin_menu_behind_background" class="pick_color_button agca_button" value="Pick color" />
|
2306 |
+
<input type="button" alt="color_admin_menu_behind_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2307 |
</td>
|
2308 |
</tr>
|
2309 |
<tr valign="center">
|
2310 |
<th><label title="Change border color of element behind admin menu" for="color_admin_menu_behind_border">Wrapper border color:</label></th>
|
2311 |
<td><input type="text" id="color_admin_menu_behind_border" name="color_admin_menu_behind_border" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_admin_menu_behind_border']); ?>" />
|
2312 |
+
<input type="button" alt="color_admin_menu_behind_border" class="pick_color_button agca_button" value="Pick color" />
|
2313 |
+
<input type="button" alt="color_admin_menu_behind_border" class="pick_color_button_clear agca_button" value="Clear" />
|
2314 |
</td>
|
2315 |
</tr>
|
2316 |
<?php } ?>
|
2330 |
<tr valign="center">
|
2331 |
<th><label title="Change color in content text" for="color_font_content">Content text color:</label></th>
|
2332 |
<td><input type="text" id="color_font_content" name="color_font_content" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_font_content']); ?>" />
|
2333 |
+
<input type="button" alt="color_font_content" class="pick_color_button agca_button" value="Pick color" />
|
2334 |
+
<input type="button" alt="color_font_content" class="pick_color_button_clear agca_button" value="Clear" />
|
2335 |
</td>
|
2336 |
</tr>
|
2337 |
<tr valign="center">
|
2338 |
<th><label title="Change color of admin bar text" for="color_font_header">Admin bar text color:</label></th>
|
2339 |
<td><input type="text" id="color_font_header" name="color_font_header" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_font_header']); ?>" />
|
2340 |
+
<input type="button" alt="color_font_header" class="pick_color_button agca_button" value="Pick color" />
|
2341 |
+
<input type="button" alt="color_font_header" class="pick_color_button_clear agca_button" value="Clear" />
|
2342 |
</td>
|
2343 |
</tr>
|
2344 |
<tr valign="center">
|
2345 |
<th><label title="Change color in fotter text" for="color_font_footer">Footer text color:</label></th>
|
2346 |
<td><input type="text" id="color_font_footer" name="color_font_footer" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_font_footer']); ?>" />
|
2347 |
+
<input type="button" alt="color_font_footer" class="pick_color_button agca_button" value="Pick color" />
|
2348 |
+
<input type="button" alt="color_font_footer" class="pick_color_button_clear agca_button" value="Clear" />
|
2349 |
</td>
|
2350 |
</tr>
|
2351 |
<tr valign="center">
|
2358 |
<tr valign="center">
|
2359 |
<th><label title="Change color in header text" for="color_widget_bar">Title bar background color:</label></th>
|
2360 |
<td><input type="text" id="color_widget_bar" name="color_widget_bar" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_widget_bar']); ?>" />
|
2361 |
+
<input type="button" alt="color_widget_bar" class="pick_color_button agca_button" value="Pick color" />
|
2362 |
+
<input type="button" alt="color_widget_bar" class="pick_color_button_clear agca_button" value="Clear" />
|
2363 |
</td>
|
2364 |
</tr>
|
2365 |
<tr valign="center">
|
2366 |
<th><label title="Change widget background color" for="color_widget_background">Background color:</label></th>
|
2367 |
<td><input type="text" id="color_widget_background" name="color_widget_background" class="color_picker" value="<?php echo htmlspecialchars($this->colorizer['color_widget_background']); ?>" />
|
2368 |
+
<input type="button" alt="color_widget_background" class="pick_color_button agca_button" value="Pick color" />
|
2369 |
+
<input type="button" alt="color_widget_background" class="pick_color_button_clear agca_button" value="Clear" />
|
2370 |
</td>
|
2371 |
</tr>
|
2372 |
</table>
|
2417 |
</th>
|
2418 |
<td id="import_file_area">
|
2419 |
<div id="export_settings_additional" style="display: none" ><input type="checkbox" id="export_settings_include_admin_menu" name="export_settings_include_admin_menu" /> <label title="Includes 'Admin Menu' configuration in exported settings.</br>Include admin menu settings only if your admin menu looks the same on multiple sites.</br>If configurations are different, imported menu settings could be wrong. In that case, use 'Reset Settings' button from 'Admin Menu' section.</br>(Custom buttons and menu configuration will be included anyway)">Include Admin Menu(?)</label></div>
|
2420 |
+
<input class="agca_button" type="button" name="agca_export_settings" value="Export Settings" onclick="exportSettings();"/></br>
|
2421 |
<input type="file" id="settings_import_file" name="settings_import_file" style="display: none"/>
|
2422 |
<input type="hidden" id="_agca_import_settings" name="_agca_import_settings" value="false" />
|
2423 |
<input type="hidden" id="_agca_export_settings" name="_agca_export_settings" value="false" />
|
2424 |
+
<input class="agca_button" type="button" name="agca_import_settings" value="Import Settings" onclick="importSettings();"/>
|
2425 |
</td>
|
2426 |
|
2427 |
|
2440 |
</div>
|
2441 |
|
2442 |
<br />
|
2443 |
+
<br /><br /><br /><p id="agca_footer_support_info">WordPress 'AG Custom Admin' plugin by Argonius. If you have any questions, ideas for future development or if you found a bug or having any issues regarding this plugin, please visit plugin's <a target="_blank" href="http://agca.argonius.com/ag-custom-admin/">SUPPORT</a> page. <br /><br />You can also support development of this plugin if you <a target="_blank" href="http://agca.argonius.com/ag-custom-admin/support-for-future-development">Make a donation</a>. Thanks!<br /><br />Have a nice blogging!</p><br />
|
2444 |
<?php
|
2445 |
}
|
2446 |
}
|
readme.txt
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
=== AG Custom Admin ===
|
2 |
Contributors: argonius
|
3 |
-
Donate link: http://
|
4 |
Tags: admin, customize, hide, change admin
|
5 |
Requires at least: 3.0
|
6 |
-
Tested up to: 3.
|
7 |
-
Stable tag: 1.2.
|
8 |
-
|
9 |
Hide or change items in admin panel. Customize buttons from admin menu. Colorize admin and login page with custom colors.
|
10 |
|
11 |
== Description ==
|
@@ -19,6 +19,7 @@ Here is the list of options:
|
|
19 |
- Hide admin bar on front end
|
20 |
- Change admin bar logo and link
|
21 |
- Hide admin bar WordPress logo
|
|
|
22 |
- Add custom admin bar logo
|
23 |
- Hide admin bar dropdown menus
|
24 |
- Hide "New" dropdown items
|
@@ -75,8 +76,9 @@ Here is the list of options:
|
|
75 |
- Add custom JavaScript
|
76 |
- Export/import customization settings
|
77 |
|
|
|
78 |
|
79 |
-
For more information about the plugin please
|
80 |
|
81 |
== Installation ==
|
82 |
|
@@ -100,7 +102,7 @@ Go to browser's console and see if there are any errors. Try to locate them. If
|
|
100 |
|
101 |
= Plugin does not work =
|
102 |
Try clearing browser's cache. If that does not work, go to browser's console and see if there are any errors. Try to locate them. If you can't fix error by yourself, post it back to plugin's support page. When trying to locate the problem, the best way is to disable other plugins, because there could be a conflict with them. If there is a conflict with other plugin, it can be found by disabling one by one plugin, until the problem is solved.
|
103 |
-
|
104 |
|
105 |
== Screenshots ==
|
106 |
|
@@ -111,6 +113,22 @@ Try clearing browser's cache. If that does not work, go to browser's console and
|
|
111 |
|
112 |
== Changelog ==
|
113 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
114 |
= 1.2.6.5 =
|
115 |
* using capabilities instead of user levels
|
116 |
* define who is admin with choosing capability (Advanced tab)
|
@@ -261,10 +279,15 @@ Try clearing browser's cache. If that does not work, go to browser's console and
|
|
261 |
|
262 |
== Upgrade Notice ==
|
263 |
|
|
|
|
|
|
|
|
|
|
|
|
|
264 |
= 1.2.6.5 =
|
265 |
New features and bug fixes. Improved colorizer, fixed admin bar issues, using capabilities to define admin users, added new options for login page, options to remove AGCA scripts on front-end. Using collapsed menus.
|
266 |
|
267 |
-
|
268 |
= 1.2.6.4 =
|
269 |
Bug fixes. Removing plugin's option on uninstall, not on deactivation.
|
270 |
|
1 |
=== AG Custom Admin ===
|
2 |
Contributors: argonius
|
3 |
+
Donate link: http://agca.argonius.com/ag-custom-admin/support-for-future-development
|
4 |
Tags: admin, customize, hide, change admin
|
5 |
Requires at least: 3.0
|
6 |
+
Tested up to: 3.5.1
|
7 |
+
Stable tag: 1.2.7
|
8 |
+
|
9 |
Hide or change items in admin panel. Customize buttons from admin menu. Colorize admin and login page with custom colors.
|
10 |
|
11 |
== Description ==
|
19 |
- Hide admin bar on front end
|
20 |
- Change admin bar logo and link
|
21 |
- Hide admin bar WordPress logo
|
22 |
+
- Add custom image in admin header
|
23 |
- Add custom admin bar logo
|
24 |
- Hide admin bar dropdown menus
|
25 |
- Hide "New" dropdown items
|
76 |
- Add custom JavaScript
|
77 |
- Export/import customization settings
|
78 |
|
79 |
+
**IMPORTANT**: AG Custom Admin should always be updated before updating WordPress. If you are unable to login or you have any other problems, please check our [FAQ](http://wordpress.org/extend/plugins/ag-custom-admin/faq/) and [SUPPORT](http://wordpress.org/support/plugin/ag-custom-admin) page.
|
80 |
|
81 |
+
For more information about the plugin please check [PLUGIN WEBSITE](http://agca.argonius.com/ag-custom-admin/)
|
82 |
|
83 |
== Installation ==
|
84 |
|
102 |
|
103 |
= Plugin does not work =
|
104 |
Try clearing browser's cache. If that does not work, go to browser's console and see if there are any errors. Try to locate them. If you can't fix error by yourself, post it back to plugin's support page. When trying to locate the problem, the best way is to disable other plugins, because there could be a conflict with them. If there is a conflict with other plugin, it can be found by disabling one by one plugin, until the problem is solved.
|
105 |
+
|
106 |
|
107 |
== Screenshots ==
|
108 |
|
113 |
|
114 |
== Changelog ==
|
115 |
|
116 |
+
= 1.2.7.1 =
|
117 |
+
* Removed AGCA script on site pages automaticaly, if user is not logged in
|
118 |
+
* Custom WordPress admin title. Using custom title templates
|
119 |
+
* Added option for removing blog title from top bar
|
120 |
+
* Fixed missaligned menu when using custom content types plugins
|
121 |
+
* Fixed bug "Save button does not work" caused by unescaped characters in footer text and custom button names
|
122 |
+
* Updated AGCA buttons styles
|
123 |
+
|
124 |
+
= 1.2.7 =
|
125 |
+
* WordPress 3.5 compatible
|
126 |
+
* Added login page background color
|
127 |
+
* Resolving jQuery script
|
128 |
+
* Added feedback buttons (postitive/negative)
|
129 |
+
* Better user's experience (updated form buttons and textboxes)
|
130 |
+
* Fixed problem with Howdy renaming
|
131 |
+
|
132 |
= 1.2.6.5 =
|
133 |
* using capabilities instead of user levels
|
134 |
* define who is admin with choosing capability (Advanced tab)
|
279 |
|
280 |
== Upgrade Notice ==
|
281 |
|
282 |
+
= 1.2.7.1 =
|
283 |
+
Bug fixes. Removing admin bar site title. Custom page titles in WP admin.
|
284 |
+
|
285 |
+
= 1.2.7 =
|
286 |
+
Plugin prepared for WordPress 3.5. Few additional improvements.
|
287 |
+
|
288 |
= 1.2.6.5 =
|
289 |
New features and bug fixes. Improved colorizer, fixed admin bar issues, using capabilities to define admin users, added new options for login page, options to remove AGCA scripts on front-end. Using collapsed menus.
|
290 |
|
|
|
291 |
= 1.2.6.4 =
|
292 |
Bug fixes. Removing plugin's option on uninstall, not on deactivation.
|
293 |
|
script/ag_script.js
CHANGED
@@ -107,8 +107,7 @@ function createEditMenuPage(checkboxes,textboxes){
|
|
107 |
});
|
108 |
|
109 |
//console.log(checkboxes.replace('<-TOP->','')+"|"+textboxes.replace('<-TOP->',''));
|
110 |
-
prettyEditMenuPage();
|
111 |
-
|
112 |
|
113 |
}
|
114 |
|
@@ -182,6 +181,85 @@ function createEditMenuPageV32(checkboxes,textboxes){
|
|
182 |
});
|
183 |
}
|
184 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
185 |
function showHideSection(text) {
|
186 |
switch(text)
|
187 |
{
|
@@ -379,16 +457,38 @@ jQuery(document).ready(function(){
|
|
379 |
jQuery("body").append("<div id='AGToolTipDiv'></div>");
|
380 |
|
381 |
/*ToolTip*/
|
382 |
-
jQuery("label[title],#agca_donate_button").each(function() {
|
383 |
-
jQuery(this).hover(function(e) {
|
384 |
-
jQuery(this).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
385 |
var tipY = e.pageY + 16;
|
386 |
var tipX = e.pageX + 16;
|
387 |
jQuery("#AGToolTipDiv").css({
|
388 |
'top': tipY,
|
389 |
-
'left': tipX
|
|
|
|
|
390 |
});
|
391 |
-
});
|
|
|
|
|
392 |
jQuery("#AGToolTipDiv")
|
393 |
.html(jQuery(this).attr('title'))
|
394 |
.stop(true,true)
|
@@ -532,7 +632,9 @@ function processData(){
|
|
532 |
if(element == 1){
|
533 |
array="";
|
534 |
}
|
535 |
-
jQuery('#ag_add_adminmenu_json').val(array);
|
|
|
|
|
536 |
|
537 |
/*Serialize colors*/
|
538 |
var array = "{";
|
@@ -547,6 +649,7 @@ function processData(){
|
|
547 |
firstElement = false;
|
548 |
});
|
549 |
array += "}";
|
|
|
550 |
if(!isSettingsImport){
|
551 |
jQuery('#ag_colorizer_json').val(array);
|
552 |
}
|
@@ -560,19 +663,13 @@ function updateTargetColor(id, color){
|
|
560 |
jQuery('html, .wp-dialog').css({
|
561 |
'background-color':color
|
562 |
});
|
563 |
-
break;
|
564 |
-
case '
|
565 |
-
jQuery('
|
566 |
-
'background':color
|
567 |
-
});
|
568 |
-
|
569 |
-
|
570 |
-
'margin':'0',
|
571 |
-
'margin-left':'146px',
|
572 |
-
'padding':'15px'
|
573 |
-
});
|
574 |
-
}
|
575 |
-
break;
|
576 |
case 'color_header':
|
577 |
jQuery('#wphead').css({
|
578 |
'background':color
|
@@ -645,7 +742,8 @@ function updateTargetColor(id, color){
|
|
645 |
'background':color
|
646 |
});
|
647 |
});
|
648 |
-
jQuery('#adminmenu .wp-submenu').css({'background':color,'margin-left':'
|
|
|
649 |
//jQuery('#adminmenu .wp-submenu').css('border','3px solid red');
|
650 |
jQuery('#adminmenu .wp-submenu ul').css({'background':'none'});
|
651 |
jQuery('#adminmenu .wp-submenu ul').css('border','none');
|
@@ -707,7 +805,7 @@ function updateTargetColor(id, color){
|
|
707 |
});
|
708 |
break;
|
709 |
case 'color_font_footer':
|
710 |
-
jQuery('#
|
711 |
'color':color
|
712 |
});
|
713 |
break;
|
@@ -918,7 +1016,12 @@ function isWPHigherOrEqualThan(targetVersion){
|
|
918 |
"3.4",
|
919 |
"3.4.1",
|
920 |
"3.4.2",
|
921 |
-
"3.5"
|
|
|
|
|
|
|
|
|
|
|
922 |
//remove sufixes, beta RC etc
|
923 |
if (wpversion.indexOf("-")!=-1){
|
924 |
var parts = wpversion.split("-");
|
107 |
});
|
108 |
|
109 |
//console.log(checkboxes.replace('<-TOP->','')+"|"+textboxes.replace('<-TOP->',''));
|
110 |
+
prettyEditMenuPage();
|
|
|
111 |
|
112 |
}
|
113 |
|
181 |
});
|
182 |
}
|
183 |
|
184 |
+
function createEditMenuPageV35(checkboxes,textboxes){
|
185 |
+
/*Create menu page in AGCA settings*/
|
186 |
+
//console.log(checkboxes);
|
187 |
+
var counter = 0;
|
188 |
+
var TBlength = textboxes.length;
|
189 |
+
if(textboxes==""){
|
190 |
+
TBlength = 9999999;
|
191 |
+
}
|
192 |
+
|
193 |
+
var topElement="";
|
194 |
+
jQuery('ul#adminmenu li').each(function(){
|
195 |
+
if(!jQuery(this).hasClass("wp-menu-separator") && !jQuery(this).hasClass("wp-menu-separator-last") && !jQuery(this).hasClass("ag-custom-button") && (jQuery(this).attr('id') !="collapse-menu") && (counter < TBlength )){
|
196 |
+
|
197 |
+
//console.log(jQuery(this).text());
|
198 |
+
//if subelement
|
199 |
+
if(jQuery(this).parent().hasClass('wp-submenu') && !jQuery(this).hasClass('wp-submenu-head')){
|
200 |
+
//console.log(jQuery(this).find('a').text());
|
201 |
+
var el = jQuery(this).find('a').clone();
|
202 |
+
el.find('span').remove();
|
203 |
+
subElement = el.html();
|
204 |
+
//console.log(jQuery(this));
|
205 |
+
//console.log(subElement);
|
206 |
+
var isHidden = "";
|
207 |
+
var sub_item_text_value;
|
208 |
+
if(textboxes ==""){
|
209 |
+
sub_item_text_value = subElement;
|
210 |
+
}else{
|
211 |
+
sub_item_text_value = textboxes[counter][1];
|
212 |
+
isHidden = checkboxes[counter][1];
|
213 |
+
}
|
214 |
+
jQuery('#ag_edit_adminmenu').append("<tr><td class='ag_admin_menu_child'><div style=\"float:left\"><a tabindex=\"-1\" href=\"javascript:void(0)\" style=\"font-weight:bold;\"title=\""+topElement+" submenu: "+subElement+"\"><span style=\"font-weight:normal\">submenu: </span>"+subElement+"</a></div><div style=\"float:right\"><input type=\"checkbox\" title=\"Remove "+topElement+" submenu: "+subElement+" from menu\" class=\""+subElement+"\" "+booleanToChecked(isHidden)+" name=\"ag_edit_adminmenu_item_sub_"+counter+"\" /></div></td><td class='ag_admin_menu_child2' ><input type=\"text\" title=\"Rename submenu item "+subElement+" with this value\" class=\""+subElement+"\" size=\"47\" value=\""+sub_item_text_value+"\" name=\"ag_edit_adminmenu_item_sub_"+counter+"\" /></td></tr>");
|
215 |
+
counter++;
|
216 |
+
}
|
217 |
+
//if top element
|
218 |
+
else if(jQuery(this).parent().attr('id') == 'adminmenu'){
|
219 |
+
//console.log(jQuery(this).attr('id'));
|
220 |
+
var el = jQuery(this).find('.wp-menu-name').clone();
|
221 |
+
el.find('span').remove();
|
222 |
+
topElement = el.text();
|
223 |
+
//console.log(topElement);
|
224 |
+
var top_item_text_value;
|
225 |
+
var isHidden = "";
|
226 |
+
if(textboxes ==""){
|
227 |
+
top_item_text_value = topElement;
|
228 |
+
}else{
|
229 |
+
top_item_text_value = textboxes[counter][1];
|
230 |
+
isHidden = checkboxes[counter][1];
|
231 |
+
}
|
232 |
+
jQuery('#ag_edit_adminmenu').append("<tr><td class='ag_admin_menu_parent'><br /><span class=\"agcaMenuEditorPlusMinus\"><span class=\"plus\">+</span><span class=\"minus\">-</span></span><a tabindex=\"0\" href=\"javascript:void(0)\" >" + topElement +"</a><div style=\"float:right\"><input title=\"Remove "+topElement+" from menu\" class=\""+jQuery(this).attr("id")+"\" type=\"checkbox\" "+booleanToChecked(isHidden)+" name=\"ag_edit_adminmenu_item_top_"+counter+"\" /></div></td><td class='ag_admin_menu_parent2' ><input title=\"Rename "+topElement+" with this value\" type=\"text\" class=\""+jQuery(this).attr("id")+"\" size=\"47\" value=\""+top_item_text_value+"\" name=\"ag_edit_adminmenu_item_top_"+counter+"\" /></td></tr>");
|
233 |
+
counter++;
|
234 |
+
}
|
235 |
+
|
236 |
+
}else if(jQuery(this).attr('id') =="collapse-menu"){
|
237 |
+
jQuery(this).remove();
|
238 |
+
}
|
239 |
+
});
|
240 |
+
|
241 |
+
//console.log(checkboxes.replace('<-TOP->','')+"|"+textboxes.replace('<-TOP->',''));
|
242 |
+
prettyEditMenuPage();
|
243 |
+
|
244 |
+
var parent = null;
|
245 |
+
var subs = 0;
|
246 |
+
jQuery('#ag_edit_adminmenu tr').each(function(){
|
247 |
+
if(jQuery(this).find('td').hasClass('ag_admin_menu_parent')){
|
248 |
+
//jQuery(this).css('color','#ffffff');
|
249 |
+
if(parent != null){
|
250 |
+
if(subs == 0){
|
251 |
+
jQuery(parent).find('.agcaMenuEditorPlusMinus').html('<span> </span>');
|
252 |
+
}
|
253 |
+
}
|
254 |
+
subs = 0;
|
255 |
+
parent = jQuery(this);
|
256 |
+
}else{
|
257 |
+
subs++;
|
258 |
+
}
|
259 |
+
|
260 |
+
});
|
261 |
+
}
|
262 |
+
|
263 |
function showHideSection(text) {
|
264 |
switch(text)
|
265 |
{
|
457 |
jQuery("body").append("<div id='AGToolTipDiv'></div>");
|
458 |
|
459 |
/*ToolTip*/
|
460 |
+
jQuery("label[title],#agca_donate_button, a.feedback").each(function() {
|
461 |
+
jQuery(this).hover(function(e) {
|
462 |
+
if(jQuery(this).hasClass('feedback')){
|
463 |
+
jQuery(this).mousemove(function(e) {
|
464 |
+
var tipY = e.pageY + 16;
|
465 |
+
var tipX = e.pageX - 236;
|
466 |
+
var type = '#fee6e6';
|
467 |
+
var border = '1px solid red';
|
468 |
+
if(jQuery(this).hasClass('positive')) {
|
469 |
+
type = '#eafee6';
|
470 |
+
border = '1px solid green';
|
471 |
+
}
|
472 |
+
jQuery("#AGToolTipDiv").css({
|
473 |
+
'top': tipY,
|
474 |
+
'left': tipX,
|
475 |
+
'background': type,
|
476 |
+
'border': border
|
477 |
+
});
|
478 |
+
});
|
479 |
+
}else{
|
480 |
+
jQuery(this).mousemove(function(e) {
|
481 |
var tipY = e.pageY + 16;
|
482 |
var tipX = e.pageX + 16;
|
483 |
jQuery("#AGToolTipDiv").css({
|
484 |
'top': tipY,
|
485 |
+
'left': tipX,
|
486 |
+
'background': '#FFFFD4',
|
487 |
+
'border': '1px solid #FFFF00'
|
488 |
});
|
489 |
+
});
|
490 |
+
}
|
491 |
+
|
492 |
jQuery("#AGToolTipDiv")
|
493 |
.html(jQuery(this).attr('title'))
|
494 |
.stop(true,true)
|
632 |
if(element == 1){
|
633 |
array="";
|
634 |
}
|
635 |
+
jQuery('#ag_add_adminmenu_json').val(array);
|
636 |
+
|
637 |
+
|
638 |
|
639 |
/*Serialize colors*/
|
640 |
var array = "{";
|
649 |
firstElement = false;
|
650 |
});
|
651 |
array += "}";
|
652 |
+
|
653 |
if(!isSettingsImport){
|
654 |
jQuery('#ag_colorizer_json').val(array);
|
655 |
}
|
663 |
jQuery('html, .wp-dialog').css({
|
664 |
'background-color':color
|
665 |
});
|
666 |
+
break;
|
667 |
+
case 'login_color_background':
|
668 |
+
jQuery('body.login').css({
|
669 |
+
'background-color':color
|
670 |
+
});
|
671 |
+
break;
|
672 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
673 |
case 'color_header':
|
674 |
jQuery('#wphead').css({
|
675 |
'background':color
|
742 |
'background':color
|
743 |
});
|
744 |
});
|
745 |
+
jQuery('#adminmenu .wp-submenu').css({'background':color,'margin-left':'0',"padding-top":roundedSidberSize+"px","padding-bottom":roundedSidberSize+"px"});
|
746 |
+
jQuery('#adminmenu .wp-has-current-submenu .wp-submenu').css("padding","0");
|
747 |
//jQuery('#adminmenu .wp-submenu').css('border','3px solid red');
|
748 |
jQuery('#adminmenu .wp-submenu ul').css({'background':'none'});
|
749 |
jQuery('#adminmenu .wp-submenu ul').css('border','none');
|
805 |
});
|
806 |
break;
|
807 |
case 'color_font_footer':
|
808 |
+
jQuery('#wpfooter, #wpfooter a').css({
|
809 |
'color':color
|
810 |
});
|
811 |
break;
|
1016 |
"3.4",
|
1017 |
"3.4.1",
|
1018 |
"3.4.2",
|
1019 |
+
"3.5",
|
1020 |
+
"3.5.1",
|
1021 |
+
"3.5.2",
|
1022 |
+
"3.5.3",
|
1023 |
+
"3.5.4",
|
1024 |
+
"3.6"];
|
1025 |
//remove sufixes, beta RC etc
|
1026 |
if (wpversion.indexOf("-")!=-1){
|
1027 |
var parts = wpversion.split("-");
|
style/ag_style.css
CHANGED
@@ -108,7 +108,7 @@ td.ag_admin_menu_parent:hover{
|
|
108 |
}
|
109 |
#agca_advertising{
|
110 |
display:block;
|
111 |
-
width:
|
112 |
height: 100px;
|
113 |
/*background-color: #cccccc;*/
|
114 |
padding: 0;
|
@@ -154,4 +154,44 @@ td.ag_admin_menu_parent:hover{
|
|
154 |
float: left;
|
155 |
margin-top:3px;
|
156 |
width: 148px;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
157 |
}
|
108 |
}
|
109 |
#agca_advertising{
|
110 |
display:block;
|
111 |
+
width:900px;
|
112 |
height: 100px;
|
113 |
/*background-color: #cccccc;*/
|
114 |
padding: 0;
|
154 |
float: left;
|
155 |
margin-top:3px;
|
156 |
width: 148px;
|
157 |
+
}
|
158 |
+
/*#agca_form input.agca_button,#agca_form #ag_add_adminmenu button{
|
159 |
+
padding: 3px 10px;
|
160 |
+
background-color:#ffffff;
|
161 |
+
} */
|
162 |
+
#agca_form input[type=button],button{
|
163 |
+
background-color:#275928;
|
164 |
+
color: #ffffff;
|
165 |
+
}
|
166 |
+
#agca_form input[type=button]:hover{
|
167 |
+
background-color:#e8fae5;
|
168 |
+
color:green;
|
169 |
+
cursor:pointer;
|
170 |
+
}
|
171 |
+
#agca_form input[type=text]{
|
172 |
+
height:28px;
|
173 |
+
width:400px;
|
174 |
+
}
|
175 |
+
#agca_form input.color_picker{
|
176 |
+
width:65px;
|
177 |
+
}
|
178 |
+
#agca_form input[type=text]:hover{
|
179 |
+
background-color: #efffef;
|
180 |
+
}
|
181 |
+
#agca_form textarea{
|
182 |
+
width:400px;
|
183 |
+
}
|
184 |
+
#agca_form textarea:hover{
|
185 |
+
background-color: #efffef;
|
186 |
+
}
|
187 |
+
#agca_form #ag_edit_adminmenu input[type=text]:hover{
|
188 |
+
background-color: #444444;
|
189 |
+
color:#ffffff;
|
190 |
+
}
|
191 |
+
#agca_form #ag_add_adminmenu input[type=text]{
|
192 |
+
width:300px;
|
193 |
+
}
|
194 |
+
#agca_form input#save_plugin_settings[type="button"]:hover{
|
195 |
+
background-color:#ffffff;
|
196 |
+
color:#ffffff;
|
197 |
}
|