Plugin Directory

Changeset 170857


Ignore:
Timestamp:
11/06/2009 04:38:42 AM (16 years ago)
Author:
jayberz
Message:

Bug Fix

Location:
custom-admin-branding/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • custom-admin-branding/trunk/custom_branding.php

    r170845 r170857  
    1515// Init plugin options to white list our options
    1616function admin_branding_options_init(){
    17     register_setting( 'admin_branding_options', 'admin_branding_link' );   
     17    register_setting( 'admin_branding_options', 'custom_admin_branding_link' );
    1818}
    1919
     
    9696// admin_branding_options_page() displays the page content for the Admin Branding Options submenu
    9797function admin_branding_options_page() {
    98 $options = get_option('admin_branding_link');
     98$options = get_option('custom_admin_branding_link');
    9999    // default options to be loaded on plugin activation
    100100    $options['top_page_border_show'] = 'normal';
     
    123123    $options['lost_password_color'] = '#21759B';
    124124    $options['lost_password_hover_color'] = '#D54E21';
    125     add_option( 'admin_branding_link', $options );
     125    add_option( 'custom_admin_branding_link', $options );
    126126 ?>
    127127 
    128128<?php
    129129// calls and variables to be loaded in WordPress admin for Live Login Preview
    130 $options = get_option('admin_branding_link');
     130$options = get_option('custom_admin_branding_link');
    131131    $top_page_border_show = $options['top_page_border_show'];
    132132    $top_page_border_color = $options['top_page_border_color'];
     
    183183                <form method="post" action="options.php">
    184184                <?php settings_fields('admin_branding_options');?>
    185                 <?php $options = get_option('admin_branding_link');?>
     185                <?php $options = get_option('custom_admin_branding_link');?>
    186186                <? $site_url = get_settings('siteurl'); ?>
    187187                <table class="form-table">
    188188                    <tr valign="top">
    189189                        <th scope="row">Top Page Border</th>       
    190                             <td>Show: <input name="admin_branding_link[top_page_border_show]" type="radio" value="normal" <?php checked('normal', $options['top_page_border_show']); ?> />
    191                 Hide: <input name="admin_branding_link[top_page_border_show]" type="radio" value="none" <?php checked('none', $options['top_page_border_show']); ?> />
    192                             <br />Color:<br /><input type="text" class="vtrColorPicker" name="admin_branding_link[top_page_border_color]" value="<?php echo $options['top_page_border_color']; ?>" /></td>
     190                            <td>Show: <input name="custom_admin_branding_link[top_page_border_show]" type="radio" value="normal" <?php checked('normal', $options['top_page_border_show']); ?> />
     191                Hide: <input name="custom_admin_branding_link[top_page_border_show]" type="radio" value="none" <?php checked('none', $options['top_page_border_show']); ?> />
     192                            <br />Color:<br /><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[top_page_border_color]" value="<?php echo $options['top_page_border_color']; ?>" /></td>
    193193                    </tr>
    194194                    <tr valign="top">
    195195                        <th scope="row">Back to Blog Link</th>       
    196                             <td>Link Color:<br /><input type="text" class="vtrColorPicker" name="admin_branding_link[back_to_blog_color]" value="<?php echo $options['back_to_blog_color']; ?>" /><br />Hover Color:<br /><input type="text" class="vtrColorPicker" name="admin_branding_link[back_to_blog_hover_color]" value="<?php echo $options['back_to_blog_hover_color']; ?>" /></td>
     196                            <td>Link Color:<br /><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[back_to_blog_color]" value="<?php echo $options['back_to_blog_color']; ?>" /><br />Hover Color:<br /><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[back_to_blog_hover_color]" value="<?php echo $options['back_to_blog_hover_color']; ?>" /></td>
    197197                    </tr>
    198198                    <tr valign="top">
    199199                        <th scope="row">Form Background</th>
    200                             <td><input type="text" class="wide" name="admin_branding_link[login_form_bg]" value="<?php echo $options['login_form_bg']; ?>" />
     200                            <td><input type="text" class="wide" name="custom_admin_branding_link[login_form_bg]" value="<?php echo $options['login_form_bg']; ?>" />
    201201                                    </td>
    202202                    </tr>
    203203                    <tr valign="top">
    204204                        <th scope="row">Input Label Color</th>
    205                             <td><input class="vtrColorPicker" type="text" name="admin_branding_link[login_form_label]" value="<?php echo $options['login_form_label']; ?>" /></td>
     205                            <td><input class="vtrColorPicker" type="text" name="custom_admin_branding_link[login_form_label]" value="<?php echo $options['login_form_label']; ?>" /></td>
    206206                    </tr>   
    207207                    <tr valign="top">
    208208                        <th scope="row">Input Text Color</th>
    209                             <td><input class="vtrColorPicker" type="text" name="admin_branding_link[input_text_color]" value="<?php echo $options['input_text_color']; ?>" /></td>
     209                            <td><input class="vtrColorPicker" type="text" name="custom_admin_branding_link[input_text_color]" value="<?php echo $options['input_text_color']; ?>" /></td>
    210210                    </tr>
    211211                    <tr valign="top">
    212212                        <th scope="row">Login Button Background</th>
    213                             <td><input type="text" class="wide" name="admin_branding_link[login_button_background]" value="<?php echo $options['login_button_background']; ?>" />
     213                            <td><input type="text" class="wide" name="custom_admin_branding_link[login_button_background]" value="<?php echo $options['login_button_background']; ?>" />
    214214                            </td>
    215215                    </tr>
    216216                    <tr valign="top">
    217217                        <th scope="row">Login Button Border Color</th>
    218                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[login_button_color]" value="<?php echo $options['login_button_color']; ?>" />
     218                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[login_button_color]" value="<?php echo $options['login_button_color']; ?>" />
    219219                            </td>
    220220                    </tr>
    221221                    <tr valign="top">
    222222                        <th scope="row">Login Button Hover Color</th>
    223                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[login_border_hover_color]" value="<?php echo $options['login_border_hover_color']; ?>" />
     223                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[login_border_hover_color]" value="<?php echo $options['login_border_hover_color']; ?>" />
    224224                            </td>
    225225                    </tr>
    226226                    <tr valign="top">
    227227                        <th scope="row">Login Button Text Color</th>
    228                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[login_text_color]" value="<?php echo $options['login_text_color']; ?>" /></td>
     228                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[login_text_color]" value="<?php echo $options['login_text_color']; ?>" /></td>
    229229                    </tr>
    230230                    <tr valign="top">
    231231                        <th scope="row">Lost Your Password Link</th>       
    232                             <td>Link Color:<br /><input type="text" class="vtrColorPicker" name="admin_branding_link[lost_password_color]" value="<?php echo $options['lost_password_color']; ?>" /><br />Hover Color:<br /><input type="text" class="vtrColorPicker" name="admin_branding_link[lost_password_hover_color]" value="<?php echo $options['lost_password_hover_color']; ?>" /></td>
     232                            <td>Link Color:<br /><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[lost_password_color]" value="<?php echo $options['lost_password_color']; ?>" /><br />Hover Color:<br /><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[lost_password_hover_color]" value="<?php echo $options['lost_password_hover_color']; ?>" /></td>
    233233                    </tr>
    234234                </table>
     
    244244                    <tr valign="top">
    245245                        <th scope="row">Admin Header Logo</th>
    246                             <td><input type="text" class="wide" name="admin_branding_link[admin_header_logo]" value="<?php echo $options['admin_header_logo']; ?>" /></td>
     246                            <td><input type="text" class="wide" name="custom_admin_branding_link[admin_header_logo]" value="<?php echo $options['admin_header_logo']; ?>" /></td>
    247247                    </tr>
    248248                    <tr valign="top">
    249249                        <th scope="row">Admin Header Background Color</th>
    250                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[admin_header_bg_clr]" value="<?php echo $options['admin_header_bg_clr']; ?>" /></td>
     250                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[admin_header_bg_clr]" value="<?php echo $options['admin_header_bg_clr']; ?>" /></td>
    251251                    </tr>
    252252                    <tr valign="top">
    253253                        <th scope="row">Favorite Actions Button Color</th>
    254                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[fav_actions_btn_color]" value="<?php echo $options['fav_actions_btn_color']; ?>" /></td>
     254                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[fav_actions_btn_color]" value="<?php echo $options['fav_actions_btn_color']; ?>" /></td>
    255255                    </tr>
    256256                    <tr valign="top">
    257257                        <th scope="row">Favorite Actions Button Background</th>
    258                             <td><input type="text" class="wide" name="admin_branding_link[fav_actions_btn_background]" value="<?php echo $options['fav_actions_btn_background']; ?>" /></td>
     258                            <td><input type="text" class="wide" name="custom_admin_branding_link[fav_actions_btn_background]" value="<?php echo $options['fav_actions_btn_background']; ?>" /></td>
    259259                    </tr>
    260260                    <tr valign="top">
    261261                        <th scope="row">Favorite Actions Button Border Color</th>
    262                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[fav_actions_bdr]" value="<?php echo $options['fav_actions_bdr']; ?>" /></td>
     262                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[fav_actions_bdr]" value="<?php echo $options['fav_actions_bdr']; ?>" /></td>
    263263                    </tr>
    264264                    <tr valign="top">
    265265                        <th scope="row">User Info Text Color</th>
    266                             <td><input type="text" class="vtrColorPicker" name="admin_branding_link[user_info_txt]" value="<?php echo $options['user_info_txt']; ?>" /></td>
     266                            <td><input type="text" class="vtrColorPicker" name="custom_admin_branding_link[user_info_txt]" value="<?php echo $options['user_info_txt']; ?>" /></td>
    267267                    </tr>
    268268                    <tr valign="top">
    269269                        <th scope="row">User Info Link Color</th>
    270                             <td>Link Color:<br /><input class="vtrColorPicker" type="text" name="admin_branding_link[user_info_lnk]" value="<?php echo $options['user_info_lnk']; ?>" /><br />Hover Color:<br /><input class="vtrColorPicker" type="text" name="admin_branding_link[user_info_lnk_hvr]" value="<?php echo $options['user_info_lnk_hvr']; ?>" /></td>
     270                            <td>Link Color:<br /><input class="vtrColorPicker" type="text" name="custom_admin_branding_link[user_info_lnk]" value="<?php echo $options['user_info_lnk']; ?>" /><br />Hover Color:<br /><input class="vtrColorPicker" type="text" name="custom_admin_branding_link[user_info_lnk_hvr]" value="<?php echo $options['user_info_lnk_hvr']; ?>" /></td>
    271271                    </tr>
    272272                </table>
     
    282282                <tr valign="top">
    283283                    <th scope="row">Admin Footer Logo</th>
    284                         <td><input type="text" class="wide" name="admin_branding_link[admin_footer_logo]" value="<?php echo $options['admin_footer_logo']; ?>" /></td>
     284                        <td><input type="text" class="wide" name="custom_admin_branding_link[admin_footer_logo]" value="<?php echo $options['admin_footer_logo']; ?>" /></td>
    285285                </tr>
    286286                <tr valign="top">
    287287                    <th scope="row">Footer Link <br /><em>(use full url)</em></th>
    288                         <td><input type="text" class="wide" name="admin_branding_link[footer_link]" value="<?php echo $options['footer_link']; ?>" /></td>
     288                        <td><input type="text" class="wide" name="custom_admin_branding_link[footer_link]" value="<?php echo $options['footer_link']; ?>" /></td>
    289289                </tr>
    290290            </table>
     
    422422/*This is the function that displays the custom login screen.*/
    423423function custom_login() {
    424 $options = get_option('admin_branding_link');
     424$options = get_option('custom_admin_branding_link');
    425425    $top_page_border_show = $options['top_page_border_show'];
    426426    $top_page_border_color = $options['top_page_border_color'];
     
    500500/*This function places the custom header graphic at the top of every WordPress Admin page.*/
    501501function custom_header() {
    502 $options = get_option('admin_branding_link');
     502$options = get_option('custom_admin_branding_link');
    503503    $admin_header_bg_img = $options['admin_header_bg_img'];
    504504    $admin_header_bg_clr = $options['admin_header_bg_clr'];
     
    571571
    572572function custom_footer() {
    573 $options = get_option('admin_branding_link');
     573$options = get_option('custom_admin_branding_link');
    574574    $footer_link = $options["footer_link"];
    575575    $admin_footer_logo = $options['admin_footer_logo'];
  • custom-admin-branding/trunk/readme.txt

    r170845 r170857  
    22Contributors: jayberz
    33Donate link: http://redlettersstudio.com/wordpress-custom-admin-branding/
    4 Tags: branding, logos, admin, custom
     4Tags: branding, logos, admin, custom, images, header, footer, login
    55Requires at least: 2.7
    66Tested up to: 2.9
    7 Stable tag: 2.0
     7Stable tag: 2.0.1
    88
    9 The Custom Admin Branding Plugin allows you to brand your WordPress install for clients.  You can display custom images and styles for the login screen, admin header and footer.
     9The Custom Admin Branding Plugin allows you to brand and customize the WordPress administration area for clients or for personal use.  You can display custom images and styles for the login screen, admin header and footer.
    1010
    1111== Description ==
    1212
    13 The Custom Admin Branding Plugin allows you to re-brand the Wordpress login screen, the admin header and footer with your own custom images.
     13The Custom Admin Branding Plugin allows you to brand and customize the WordPress administration area for clients or for personal use.  You can display custom images and styles for the login screen, admin header and footer.
    1414
    1515It should be fairly easy to use for anyone familiar with Wordpress and has basic css and html skills. At its simplest it only requires you to activate and then replace three images with your own. Photoshop templates are included to help you with that.
    1616
    17 **Get more support at [the official Custom Admin Branding page](http://redlettersstudio.com/blog/wordpress-blog/admin/wordpress-custom-admin-branding/).**
     17**Get more support at [the official Custom Admin Branding page](http://redlettersstudio.com/wordpress-custom-admin-branding/).**
    1818
    1919== Installation ==
     
    23233. Go to the plugin section in your admin and activate
    2424
    25 =Customization=
    26 
    2725**Changing Colors**
    28 The options that support color change have a swatch next to the form field. You can either click the color swatch or click into the form field. Doing so will bring up a pallete of color options. You are not restrcited by the choices in the pallete. You can enter any 6 figure hexidecial color code. You must however precede your code with the pound sign (#).
     26The options that support color change have a swatch next to the form field. You can either click the color swatch or click into the form field. Doing so will bring up a palette of color options. You are not restricted by the choices in the palette. You can enter any 6 figure hexadecimal color code. You must however precede your code with the pound sign (#).
    2927
    3028**Customizing Images**
     
    3937All of the default images are in the images folder which is in the custom-admin-branding plugin folder. To change an image:
    4038
    41 1. Create your custom images with the provided Photoshop templates. (They are in the psd_image_templates folder)
     391. Create your custom images with the provided Photoshop templates. (They are in the psd-image-templates folder)
    42402. Upload your custom image(s) to the images folder.
    43413. Enter the file name of the image you wish to use in the proper form field in the options page.
     
    6361
    6462== Changelog ==
     63
     64= 2.0.1 =
     65* Fixed a bug in the database calls
    6566
    6667= 2.0 =
Note: See TracChangeset for help on using the changeset viewer.