I have some difficulies styling Meta Box content of a custom post. No CSS styling is applied. I made a really simple testbased on what I have read on the other post here.
metabox creation:
add_meta_box('wpptabs_company_details', __('The Meta box name', 'wpptabs'), array(&$this, 'render_meta_content'), 'wpptabs', 'normal', 'high');
Meteabox content:
<label> THIS IS TEST </label>
This is waht I have tried with css
.postbox label{color : red!important; }
#meta_wpptabs_company_details .postbox label{color : red!important; }
#meta_wpptabs_company_details label{color : red!important; }
#wpptabs_company_details .postbox label {color : red!important; }
#wpptabs_company_details label {color : red!important; }
#meta_wpptabs_company_details {color : red!important; }
label {color : red!important; }
This is how it looks like in Chrome with "inspect element" -> link When I wite directly to element.style{} it works, but when I add a new style rule with '+' button a label{} field appears and when I write the style in it it does not work.
Here is some evidence the css is loaded: -> link
and this is how it looks in page source in header
<link rel='stylesheet' id='wpptabs-config-table-css-css' href='http://namio.pl/wp-content/plugins/wp-pricing-tables/css/admin.css?ver=null' type='text/css' media='false' />
And this is how I load the css:
class MyClass {
function __construct() {
add_action('admin_enqueue_scripts', array(&$this,'wpptabs_table_modifier'));
add_action('admin_print_styles', array(&$this,'wpptabs_enqueue_styles'));
}
function wpptabs_enqueue_styles() {
global $typenow; if ($typenow=="wpptabs") {
wp_register_style('wpptabs-config-table-css', WPPTABS_URLPATH . '/css/admin.css', 'null', 'null', 'false');
wp_enqueue_style('wpptabs-config-table-css');
}
}
I have no idea what else it could be. If some more details are needed please let me know.