WordPress.org

Ready to get started?Download WordPress

Forums

Edit Flow
[resolved] Adding color to statuses (3 posts)

  1. pauisanoun
    Member
    Posted 2 years ago #

    Thanks for a great plugin! I have been trying to figure out a way to colorize posts by status, so that they are easily recognizable when looking through the All Posts list. I found a plugin called Color Admin Posts that has helped, but only on some of the default statuses (Draft, Pending, Private, Future, Published). I'd like to expand these to include the custom statuses that are generated by the Edit Flow plugin. How can I identify the custom statuses in the code so that I can try to change their background color, like this: http://screencast.com/t/FgFHSly66

    Thanks for any

    http://wordpress.org/extend/plugins/edit-flow/

  2. Daniel Bachhuber
    Hand Built
    Plugin Author

    Posted 2 years ago #

    Yep, it should be pretty easy to do. Each table row has a "status-slug" class where "slug" is the slug of your custom status. You can stylize the entire table row with something like this (untested):

    add_action( 'admin_head', 'efx_custom_status_css' );
    function efx_custom_status_css() {
    	global $pagenow;
    	if ( 'edit.php' != $pagenow )
    		return;
    	?>
    	table.wp-list-table tr.status-pitch {
    		background-color: red;
    	}
    	<?php
    }

    Obviously you'll want to change the CSS a bit :)

    Hope this helps!

  3. pauisanoun
    Member
    Posted 2 years ago #

    Oh great, thanks for all your help, Daniel! I'll give it a shot.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic