Add admin body classes for the WP branch, WP version, and current admin color. props andy, fixes #17496.

git-svn-id: https://develop.svn.wordpress.org/trunk@17957 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin
2011-05-18 18:11:48 +00:00
parent 52dfe62ebf
commit c220a69d42

View File

@@ -85,6 +85,10 @@ if ( get_user_setting('mfold') == 'f' )
if ( is_admin_bar_showing() )
$admin_body_class .= ' admin-bar';
$admin_body_class .= ' branch-' . str_replace( '.', '-', floatval( $wp_version ) );
$admin_body_class .= ' version-' . str_replace( '.', '-', preg_replace( '/^([.0-9]+).*/', '$1', $wp_version ) );
$admin_body_class .= ' admin-color-' . sanitize_html_class( get_user_option( 'admin_color' ), 'fresh' );
if ( $is_iphone ) { ?>
<style type="text/css">.row-actions{visibility:visible;}</style>
<?php } ?>