Created
January 13, 2012 22:06
-
-
Save jaredatch/1608960 to your computer and use it in GitHub Desktop.
Menu icons for custom post types
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'admin_head', 'ja_custom_cpt_icons' ); | |
function ja_custom_cpt_icons() { ?> | |
<style type="text/css" media="screen"> | |
#menu-posts-portfolio .wp-menu-image { | |
background: url(<?php echo plugin_dir_url( __FILE__ ); ?>images/portfolio-icon.png) no-repeat 6px 6px !important; | |
} | |
#menu-posts-portfolio:hover .wp-menu-image, #menu-posts-portfolio.wp-has-current-submenu .wp-menu-image { | |
background-position:6px -16px !important; | |
} | |
#icon-edit.icon32-posts-portfolio {background: url(<?php echo plugin_dir_url( __FILE__ ); ?>images/portfolio-32x32.png) no-repeat;} | |
</style> | |
<?php } | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment