WordPress.org

Make WordPress Core

Changeset 17957


Ignore:
Timestamp:
05/18/11 18:11:48 (4 years ago)
Author:
nacin
Message:

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-header.php

    r17853 r17957  
    8686    $admin_body_class .= ' admin-bar'; 
    8787 
     88$admin_body_class .= ' branch-' . str_replace( '.', '-', floatval( $wp_version ) ); 
     89$admin_body_class .= ' version-' . str_replace( '.', '-', preg_replace( '/^([.0-9]+).*/', '$1', $wp_version ) ); 
     90$admin_body_class .= ' admin-color-' . sanitize_html_class( get_user_option( 'admin_color' ), 'fresh' ); 
     91 
    8892if ( $is_iphone ) { ?> 
    8993<style type="text/css">.row-actions{visibility:visible;}</style> 
Note: See TracChangeset for help on using the changeset viewer.