plugin-icon

Smart User Slug Hider

隐藏作者页面链接中的用户名以增强安全性
评级
4.9
最后更新
April 17, 2024
版本
4.0.6
活跃安装
4K

The Smart User Slug Hider Plugin hides usernames in Author Pages URLs to enhance Security

Retired Plugin

Development, maintenance and support of this plugin has been retired in october 2023. You can use this plugin as long as is works for you.

There will be no more updates and I won’t answer any support questions. Thanks for your understanding.

Feel free to fork this plugin.

使用

本插件自动以16位代码串替换用户名。无需设置,开箱即用。取消激活插件会恢复默认的 WordPress 配置。

为什么使用这个插件?

WordPress 的作者页面链接使用诸如example.com/author/name这样的形式,其中的name表示用户的登录名。

这意味着您网站的所有用户的用户名将公开可见,这是一个很大的安全隐患。

Smart User Slug Hider插件将所有像example.com/author/john的作者页面链接变成类似example.com/author/e9e716def73f76ac的样式。

这个代码是自动生成的,且无法逆推出用户名。访问 WordPress 默认的 URL 将提示 404(未找到)错误。

短代码

该插件添加了三个可在文章中使用的短代码:

  • [smart_user_slug] —— 文章作者个人资料页面的 user slug —— 例:e9e716def73f76ac
  • [smart_user_url] —— 文章作者个人资料页面的 url —— 例:example.com/author/e9e716def73f76ac
  • [smart_user_link] —— 添加一个通向文章作者的个人资料页面的链接

主题函数

本插件添加了两个可在主题文件中使用的函数:

  • get_smart_user_slug( $author_id ) 用来获取 the user slug for the author —— 作者的user slug —— 其中的 $author_id 参数是可选的, 如果省略,则获取当前文章的作者 ID 。
  • the_smart_user_slug( $author_id ) 用来显示作者的user slug —— 其中的 $author_id 参数是可选的, 如果省略,则显示当前文章的作者 ID 。

插件隐私信息

  • 本插件不设置 cookies
  • 本插件不会收集或存储任何数据
  • 本插件不会将任何数据传输到其他服务器上
免费使用Creator套餐
活跃安装
4K
目前已测试版本
6.3.5
此插件可供下载,可用于您的 WordPress 自托管安装。