wordpress 编辑_批准后如何让贡献者编辑WordPress帖子

wordpress 编辑

Recently one of our readers asked if it was possible to allow contributors to edit their approved posts? WordPress user roles allow you to set different permissions for each user on your site. By default, a WordPress user with a contributor role can’t modify their published posts. In this article, we will show you how to let contributors edit their posts after being approved.

最近,我们的一位读者问:是否可以允许贡献者编辑其批准的帖子? WordPress 用户角色允许您为站点上的每个用户设置不同的权限。 默认情况下,具有贡献者角色的WordPress用户无法修改其发布的帖子。 在本文中,我们将向您展示如何使贡献者在获得批准后编辑其帖子。

Let Contributors Edit Their Posts After Being Approved
让贡献者在获得批准后编辑其帖子 (Let Contributors Edit Their Posts After Being Approved)

Contributors or guest authors with contributor user role write posts and send them to review in WordPress. A user with the administrator or editor user role can review and publish it. Once published, the contributors are unable to edit their own posts. This is a generalized hierarchy in WordPress that distribute user role and status.

具有贡献者用户角色的贡献者或来宾作者撰写帖子,并将其发送给WordPress中的审阅者。 具有管理员或编辑者用户角色的用户可以查看和发布它。 发布后,贡献者将无法编辑自己的帖子。 这是WordPress中的通用层次结构,用于分发用户角色和状态。

However, you can add or remove capabilities to user roles in WordPress. Let’s take a look at how to let contributors edit their published posts.

但是,您可以在WordPress中为用户角色添加或删除功能 。 让我们看一下如何让贡献者编辑他们发布的帖子。

方法1:允许贡献者编辑他们的帖子(插件) (Method 1: Allow Contributors to Edit Their Posts (Plugin))

This method is easier and recommended for most users. This method also allows you to edit other user roles and permissions right away.

此方法更简单,建议大多数用户使用。 此方法还允许您立即编辑其他用户角色和权限。

First thing you need to do is install and activate the Capability Manager Enhanced plugin. For more details, see our step by step guide on how to install a plugin in WordPress.

您需要做的第一件事是安装并激活Capability Manager Enhanced插件。 有关更多详细信息,请参阅有关如何在WordPress中安装插件的分步指南。

Upon activation, you need to visit Users » Capabilities in your WordPress admin area to edit capabilities of contributor user role.

激活后,您需要在WordPress管理区域中访问用户»功能 ,以编辑贡献者用户角色的功能。

User Capabilities

On this page, you need to select Contributor role on the right side, so you can change their permission level.

在此页面上,您需要在右侧选择贡献者角色,以便可以更改其权限级别。

Select Contributor Role

Once selected, you’ll see a lot of options in this section. In the Editing Capabilities area, you need to select Edit Published option and scroll to the bottom to click on Save Changes button.

选择之后,您将在本节中看到很多选项。 在“ 编辑功能”区域中,需要选择“ 编辑已发布”选项,然后滚动到底部以单击“ 保存更改”按钮。

Select Edit Published

After that you can test the permissions by switching to a contributor role in WordPress and going to the Posts page. You will now see the option to edit published posts. Hint: you can instantly switch between user accounts while testing roles and permissions in WordPress.

之后,您可以通过切换到WordPress中的贡献者角色并转到“ 帖子”页面来测试权限。 现在,您将看到编辑已发布帖子的选项。 提示:您可以在测试WordPress中的角色和权限时立即在用户帐户之间切换

Edit Approved Posts
方法2:手动允许贡献者编辑他们的帖子 (Method 2: Manually Allowing Contributor to Edit Their Posts)

This method requires you to add code to your WordPress files. If you haven’t done this before, then please take a look at our guide on how to copy and paste code in WordPress.

此方法要求您将代码添加到WordPress文件中。 如果您以前没有做过,请查看我们的指南, 了解如何在WordPress中复制和粘贴代码

You’ll need to add the following code to your WordPress theme’s functions.php file or site-specific plugin.

您需要将以下代码添加到WordPress主题的functions.php文件特定于站点的插件中



// get the "contributor" role object
$obj_existing_role = get_role( 'contributor' );

// add the "Edit published posts" capability
$obj_existing_role->add_cap( 'edit_published_posts' );


This code snippet needs to run only once which means you can save it and then delete it. It will allow contributors to edit their published posts in WordPress.

该代码段只需运行一次,这意味着您可以保存然后删除它。 它将允许贡献者在WordPress中编辑其发布的帖子。

Even though we have shown you how to allow contributors to edit their published posts, we believe it is not a good practice to let contributors or authors edit their published content.

即使我们已经向您展示了如何允许贡献者编辑其已发布的帖子,但我们认为让贡献者或作者来编辑其已​​发布的内容不是一个好习惯。

If there’s a need for any change or correction in the content, then the writer should ask an administrator or editor to update it. This allows you to maintain editorial integrity.

如果需要对内容进行任何更改或更正,则编写者应要求管理员或编辑者对其进行更新。 这使您可以保持编辑的完整性。

Before publishing a post, an editor checks multiple necessary elements like keywords, images, meta description, URL, and more. These things are important to get better rankings in search results. A user with a contributor user role may not be fully aware of your editorial best practices and can make mistakes that would go unnoticed if not reviewed by an editor or administrator.

在发布帖子之前,编辑者会检查多个必要的元素,例如关键字,图像,元描述,URL等。 这些事情对于在搜索结果中获得更好的排名很重要。 具有贡献者用户角色的用户可能不完全了解您的编辑最佳实践,并且可能会犯错误,如果未得到编辑或管理员的审查,这些错误将不会引起注意。

One way to deal with this is by sharing a blog post checklist with your contributors and authors. This checklist will help them cover all the tasks before submitting a post to review. It will also help an editor to quickly review a post.

解决此问题的一种方法是与您的贡献者和作者共享博客帖子清单 。 此清单将帮助他们在提交帖子进行审阅之前涵盖所有任务。 它还将帮助编辑者快速查看帖子。

We hope this article helped you learn how to let contributors edit their posts after being approved. You may also want to see our guide on how to allow users to submit posts in WordPress without even accessing the WordPress admin area.

我们希望本文能帮助您学习如何使贡献者在获得批准后编辑其帖子。 您可能还想查看我们的指南,以了解如何允许用户甚至无需访问WordPress管理区域即可在WordPress中提交帖子

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

如果您喜欢这篇文章,请订阅我们的YouTube频道 WordPress视频教程。 您也可以在TwitterFacebook上找到我们。

翻译自: https://www.wpbeginner.com/wp-tutorials/how-to-let-contributors-edit-their-posts-after-being-approved/

wordpress 编辑

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值