How do I change the author of a custom post type? /WordPress
The edit author attribute is not added by default for custom post types. To add the author attribute the following code is required:
please add this code to function.php in the theme folder.
and
The edit author attribute is not added by default for custom post types. To add the author attribute the following code is required:
please add this code to function.php in the theme folder.
Kod:
function allowAuthorEditing()
{
add_post_type_support( 'mytype', 'author' );
}
and
Kod:
add_action('init','allowAuthorEditing');