[wordpress插件] BuddyPress InstabanBuddyPress Instaban

wordpress 插件 文章 2020-03-13 00:30 481 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

The BuddyPress Instaban plugin allows site administrators to quickly remove problem members with a single click from the front-end.

BuddyPress Instaban插件使站点管理员只需单击一下前端即可快速删除问题成员。

A confirmation dialog prevents accidental removals.

确认对话框可防止意外删除。

If your site uses OneAll’s Social Login plugin to allow members to create new accounts, Instaban will add their unique token to a list of ‘unsafe’ tokens.

如果您的网站使用OneAll的“社交登录”插件允许成员创建新帐户,则Instaban会将其唯一令牌添加到“不安全”令牌列表中。

Integration options with OneAll are included.

包括与OneAll的集成选项。

Features:

功能:

    • Eliminates additional steps of searching user accounts in the WordPress admin panel.
    • 省去了在WordPress管理面板中搜索用户帐户的其他步骤。

    • Integrates with member profiles on activation with predefined hooks.
    • 在激活时使用预定义的挂钩与成员配置文件集成。

    • Optionally bans members if they’ve created an account with OneAll social login.
    • 如果成员已经使用OneAll社交登录名创建了帐户,则可以选择禁止成员。

    • Confirmation dialog with AJAX handler is fast, safe and efficient.
    • 带有AJAX处理程序的确认对话框是快速,安全和高效的。

    • Ability to customize button placement in your theme with a template tag.

      能够使用模板标签自定义主题中按钮的位置。

      For integration with OneAll Social Login, you may perform a check with the user_token returned from the API response, like so:

      为了与OneAll Social Login集成,您可以对API响应返回的user_token进行检查,如下所示:

      // from oa-social-login/includes/communication.php:

      //来自oa-social-login / includes / communication.php:

      /**

      / **

        • Handle the callback

          处理回调

          */

          * /

          function oa_social_login_callback () {

          函数oa_social_login_callback(){

          //User Data

          //用户数据

          if (is_object ($social_data)) {
              

          if(is_object($ social_data)){
              

          $identity = $social_data->response->result->data->user->identity;
              

          $ identity = $ social_data->响应->结果->数据->用户->身份;
              

          $user_token = $social_data->response->result->data->user->user_token;

          $ user_token = $ social_data->响应->结果->数据->用户->用户令牌;

          // verify that user token isn't associated with an unsafe login

            //验证用户令牌是否与不安全的登录相关联

          if ( bp_instaban_is_user_token_unsafe( $user_token, 'oa_social_login_user_unsafe_tokens' ) ) {    

          如果(bp_instaban_is_user_token_unsafe($ user_token,'oa_social_login_user_unsafe_tokens')){    

          header($_SERVER['SERVER_PROTOCOL'] . ' 501 Not Implemented', true, 501);

          header($ _ SERVER ['SERVER_PROTOCOL']。'501 Not Implemented',true,501);

          // throw a 501 error    

          //抛出501错误    

          die();

          死();

          }

          }

          }

          }

          }

          }

      In the above example, the server returns an HTTP 501 error.

      在上面的示例中,服务器返回HTTP 501错误。

      This effectively prevents the user from creating an account again with the same social network provider.

      这有效地防止了用户再次使用相同的社交网络提供商创建帐户。

      You may choose to handle it differently.

      您可以选择不同的处理方式。

      In the future, OneAll may provide a hook to enable this integration without modifying the plugin directly.

      将来,OneAll可能会提供一个挂钩来启用此集成,而无需直接修改插件。

安装步骤

    1. Download, install and activate the plugin.
    2. 下载,安装并激活插件。

    3. To remove (and optionally ban) a member, simply visit their profile and click the ‘Remove and Ban User’ button.
    4. 要删除(并选择禁止)成员,只需访问其个人资料,然后单击“删除并禁止用户”按钮。

    5. Confirm the action with the dialog.
    6. 通过对话框确认操作。

    7. You’re done!
    8. 您完成了!

下载地址
https://downloads.wordpress.org/plugin/buddypress-instaban.zip
-EOF-

AI助手支持GPT4.0