WordPress.org

Ready to get started?Download WordPress

Forums

The Admin Dashboard Header (1 post)

  1. alexwg85
    Member
    Posted 1 year ago #

    Howdy all,
    I need some help on customizing the wordpress dashboard header. I want to change the colour and style of the header bar. But every code that I find doesn't seem to work. I have tried making my own plugin using the wordpress codex tutorial. Im not sure if I have given the right "hook" or "action" or wether I the lastest update has change this to become invalid? below is the code that I have used :-

    [ Moderator Note: Please post code or markup snippets between backticks or use the code button. ]

    //This is placed in my plugin folder as a .php file
    
    <?php
    /*
    Plugin Name: My Admin Theme
    Plugin URI: http://rarecompany.co.uk
    Description: My WordPress Admin Theme - Upload and Activate.
    Author: Rare Company LTD
    Version: 1.0
    Author URI: http://[ redacted don't post email addresses ]
    */
    
    function my_admin_head() {
            echo '<link rel="stylesheet" type="text/css" href="' .plugins_url('wp-admin.css', __FILE__). '">';
    }
    
    add_action('admin_head', 'my_admin_head');
    ?>
    //This is in my plugin, file name wp-admin.css
    #wphead {
      border-bottom: MidnightBlue 1px solid;
      background-color: #E4F0FE!important;
      background: -moz-linear-gradient(bottom,#E4F0FE,#B0C4DE);
      background: -webkit-gradient(linear,left bottom,left top,from(#E4F0FE),to(#B0C4DE));
    }

    I not sure what i have done wrong, I followed the tutorial on this codex page http://codex.wordpress.org/Creating_Admin_Themes

Topic Closed

This topic has been closed to new replies.

About this Topic