|
|
@@ -387,3 +387,20 @@ function custom_publication_column( $column, $post_id ) {
|
|
387
|
387
|
break;
|
|
388
|
388
|
}
|
|
389
|
389
|
}
|
|
|
390
|
+// Add Author to Custom Post Type
|
|
|
391
|
+function add_author_support_to_posts() {
|
|
|
392
|
+ $args = array(
|
|
|
393
|
+ 'public' => true,
|
|
|
394
|
+ '_builtin' => false
|
|
|
395
|
+ );
|
|
|
396
|
+
|
|
|
397
|
+ $output = 'names';
|
|
|
398
|
+
|
|
|
399
|
+ $post_types = get_post_types( $args, $output );
|
|
|
400
|
+
|
|
|
401
|
+ foreach ( $post_types as $post_type ) {
|
|
|
402
|
+ add_post_type_support( $post_type, 'author' );
|
|
|
403
|
+ }
|
|
|
404
|
+
|
|
|
405
|
+}
|
|
|
406
|
+add_action( 'init', 'add_author_support_to_posts' );
|