Blog for web developers

Custom admin css code

Custom admin css code

In this articles we will show you how easily you can create a custom admin css code to customize your admin dashboard. WordPress is one of the best cms for blog and creating websites. Its easy to use and its plugin are easy available.

Custom admin css code

Paste the below code into your function.php
This code is going to append the link href code into your wordpress admin. add_action is the function where you pass an argument of hook with a function name.


/* Stylesheet */
function link_to_stylesheet() {


    $url = get_settings('siteurl');
    $url = $url . '/wp-content/themes/your-theme/css/wp-admin.css';
    echo '
          <link rel="stylesheet" type="text/css" href="' . $url . '" >
          ';

}
add_action('admin_head', 'link_to_stylesheet');

Santosh Shah

I am a JavaScript developer having enthusiasm on most frontend skills like JavaScript, HTML, CSS, SASS, node, gulp, angular etc. I love exploring new techniques and like to learn new technologies to keep my self up to date.


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.