Add column and post filter for a custom post type field on the edit.php page

First couple of handy helper functions, function my_custom_post_type() { return ‘post’; // edit this } function custom_field_status_metakey() { return ‘status’; } function custom_field_status_options() { return array( ” => __( ‘All statuses’, ‘textdomain’ ), // edit text domains ‘open’ => __( ‘Open’, ‘textdomain’ ), ‘closed’ => __( ‘Closed’, ‘textdomain’ ), ); } Add your custom column … Read more

Custom plugin: Loop through taxonomy types and update columns for all types?

The only things I see different in your code are the add_filter() and add_action() calls (e.g. the callback/function name), so you can use the same functions for all of the types: function update_dog_type_columns( $columns ) { // your code return $columns; } function update_dog_type_column( $column, $post_id ) { // your code } And then you … Read more

Buddypress function and global $bp question

Plugins load alphabetically by default. If Buddypress is alphbetically before your plugins folder name, then Buddypress will load first and it’s functions will be available. Additionally, whatever functionality depends on another plugins you can always attach to the plugins_loaded hook, which fires after all plugins are finished loading. For example: /** * Runs code after … Read more