Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Custom Post Types Appearance
- // Custom Post Type: Sermon Media: Appearance
- add_action('manage_posts_custom_column', 'sermonaudio_custom_columns');
- add_filter("manage_edit-sermonaudio_columns", "sermonaudio_edit_columns");
- function sermonaudio_edit_columns($columns){
- $columns = array(
- "cb" => "<input type=\"checkbox\" />",
- "title" => "Sermon Title",
- "date" => "Date Published",
- "description" => "Sermon Description",
- "speaker" => "Speaker",
- "series" => "Sermon Series",
- "season" => "Season",
- "topic" => "Topics",
- );
- return $columns;
- }
- function sermonaudio_custom_columns($column){
- global $post;
- switch ($column)
- {
- case "description":
- the_excerpt();
- break;
- case "season":
- echo get_the_term_list($post->ID, 'season', '', ', ','');
- break;
- case "topic":
- echo get_the_term_list($post->ID, 'topic', '', ', ','');
- break;
- case "series":
- echo get_the_term_list($post->ID, 'series', '', ', ','');
- break;
- case "speaker":
- echo get_the_term_list($post->ID, 'speaker', '', ', ','');
- break;
- }
- }
- // Custom Post Type: Staff: Appearance
- add_action('manage_pages_custom_column', 'staff_custom_columns');
- add_filter("manage_edit-staff_columns", "staff_edit_columns");
- function staff_edit_columns($columns){
- $columns = array(
- "cb" => "<input type=\"checkbox\" />",
- "title" => "Staff Member Name",
- "thumbnail" => "Picture",
- "position" => "Staff Position",
- "books" => "Favorite Books",
- "movies" => "Favorite Movies",
- "artists" => "Favorite Music Artists",
- "foods" => "Favorite Foods",
- "activities" => "Favorite Activities",
- "verses" => "Favorite Verses",
- "favorite-things" => "Other Favorite Things",
- );
- return $columns;
- }
- function staff_custom_columns($column){
- global $post;
- switch ($column)
- {
- case "position":
- echo get_the_term_list($post->ID, 'position', '', ', ','');
- break;
- case "books":
- echo get_the_term_list($post->ID, 'books', '', ', ','');
- break;
- case "movies":
- echo get_the_term_list($post->ID, 'movies', '', ', ','');
- break;
- case "artists":
- echo get_the_term_list($post->ID, 'artists', '', ', ','');
- break;
- case "foods":
- echo get_the_term_list($post->ID, 'foods', '', ', ','');
- break;
- case "activities":
- echo get_the_term_list($post->ID, 'activities', '', ', ','');
- break;
- case "verses":
- echo get_the_term_list($post->ID, 'verses', '', ', ','');
- break;
- case "favorite-things":
- echo get_the_term_list($post->ID, 'favorite-things', '', ', ','');
- break;
- case "thumbnail":
- the_post_thumbnail();
- }
- }
- // Custom Post Type: Front Page Large Featured Items: Appearance
- add_action('manage_posts_custom_column', 'ww_custom_columns');
- add_filter("manage_edit-ww_columns", "ww_edit_columns");
- function ww_edit_columns($columns){
- $columns = array(
- "cb" => "<input type=\"checkbox\" />",
- "title" => "Featured Item Name",
- "date" => "Date Published",
- "description" => "Featured Item Description",
- "ministry" => "Ministry Category",
- "thumbnail" => "Thumbnail"
- );
- return $columns;
- }
- function ww_custom_columns($column){
- global $post;
- switch ($column)
- {
- case "description":
- the_excerpt();
- break;
- case "ministry":
- echo get_the_term_list($post->ID, 'ministry', '', ', ','');
- break;
- case "thumbnail":
- the_post_thumbnail();
- }
- }
- // Custom Post Type: Front Page Small Featured Items: Appearance
- add_action('manage_posts_custom_column', 'featured_custom_columns');
- add_filter("manage_edit-featured_columns", "featured_edit_columns");
- function featured_edit_columns($columns){
- $columns = array(
- "cb" => "<input type=\"checkbox\" />",
- "title" => "Featured Item Name",
- "date" => "Date Published",
- "description" => "Featured Item Excerpt",
- "ministry" => "Ministry Category",
- "thumbnail" => "Thumbnail"
- );
- return $columns;
- }
- function featured_custom_columns($column){
- global $post;
- switch ($column)
- {
- case "description":
- the_excerpt();
- break;
- case "ministry":
- echo get_the_term_list($post->ID, 'ministry', '', ', ','');
- break;
- case "thumbnail":
- the_post_thumbnail();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement