plugin development - Custom User Role Preview Function Not Working

maybe I need some suggestions how to fix my current problem. I've created a custom user role with the following cap

maybe I need some suggestions how to fix my current problem. I've created a custom user role with the following capabilities:

array(
                'read' => true,  // true allows this capability
                'edit_posts' => true,
                'edit_published_posts' => true,
                //'edit_others_posts' => true,
                'publish_posts' => true,
                'upload_files' => true,
                'edit_others_pending_posts' => true,

                'edit_aotm' => true,  //
                'read_aotm' => true,  //
                'read_aotms' => true,  //
                'delete_aotm' => false,  //
                'delete_aotms' => false,  //
                'edit_aotms' => true,  //
                'edit_others_aotms' => false,  //
                'publish_aotms' => false,  //
                'read_private_aotms' => false,  //
                'create_aotms' => false,  //
            )

This user role can publish all posts. All other user or user roles (except the admin) only can set the post status to a custom one. So the above user role can publish them. The problem now is that the custom user role should can view the preview of this post. At the moment they can only see the preview link. But when they click this preview link (generated from wordpress) they get a 404 error.

With the capability edit_others_posts it works, or when the post is published.

Does anyone have a suggestion how to fix this problem?

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744697128a4588559.html

相关推荐

  • plugin development - Custom User Role Preview Function Not Working

    maybe I need some suggestions how to fix my current problem. I've created a custom user role with the following cap

    1天前
    20

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信