• Resolved ygagnon2016

    (@ygagnon2016)


    I can’t help but notice that this plugin doesn’t allow for me to populate one of the admin columns with the data from the “post_content_filtered” column. Is it labeled something else that isn’t obvious, maybe? Or is there a special trick that I need to employ in order to make that columns selectable and to get it to display?

    Thanks,
    – Yvan

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Stefan van den Dungen Gronovius

    (@dungengronovius)

    Hi Yvan,

    Thanks for your feedback. At this moment there is no column for this specific post field. To be honest I never use this field before so I don’t really have an idea what type of content this field could have.

    Can you give me an example of the content this field has that is different than the normal content so we can decide if a column for this field is suitable for our plugin (or not)?

    If you’re a developer, you could consider to create your own column for it using our documentation. It contains a nice toolkit to get you started.
    https://www.admincolumns.com/documentation/guides/creating-new-column-type/

    It’s a really simple column and the following snippet can be used as code for your column class:

    class AC_Column_Post_ContentFiltered extends AC_Column {
    
    	public function __construct() {
    		$this->set_label( 'Post Content Filtered' );
    		$this->set_type( 'column-post_content_filtered' );
    	}
    
    	public function get_raw_value( $post_id ) {
    		return get_post_field( 'post_content_filtered', $post_id, 'raw' );
    	}
    
    }
    Thread Starter ygagnon2016

    (@ygagnon2016)

    Thanks for this! By any chance, … is there some way that I could adapt this code snippet and just add it to my child theme’s functions.php file .. instead having to craft and activate another WordPress plugin?

    – Yvan

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘No post_content_filtered column?’ is closed to new replies.