Skip to content

Instantly share code, notes, and snippets.

@derpixler
Created May 26, 2011 12:28
Show Gist options
  • Save derpixler/993032 to your computer and use it in GitHub Desktop.
Save derpixler/993032 to your computer and use it in GitHub Desktop.
Wordpress: hook in the tag-list table
add_filter( 'manage_category_custom_column','myTestC');
function myTestC($content){
return $content;
}
@derpixler
Copy link
Author

add_filter( "manage_category_custom_column", 'myTestC', 10, 3 );

function myTestC($column_name, $id, $der){
var_dump($column_name, $id, $der);

return $content;

}

@derpixler
Copy link
Author

//create a new row
add_action( 'manage_edit-category_columns', 'myTest');
function myTest($content){
$content['test'] = 'hallo';
return $content;
}

//fill the row with content
add_filter( "manage_category_custom_column", 'myTestC', 10, 3 );
function myTestC($column_name, $columid, $termId){
var_dump($column_name, $id, $termId);
}

@bueltge
Copy link

bueltge commented May 26, 2011

this works, with WP Codex ;)
//create a new row
add_action( 'manage_edit-category_columns', 'my_test' );
function my_test( $column ) {
$column['test'] = 'hallo';
return $column;
}

//fill the row with content
add_filter( 'manage_category_custom_column', 'my_test_c', 10, 3 );
function my_test_c( $foo, $column_name, $term_id ) {
var_dump( $column_name, $term_id );
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment