跳至内容
WordPress.org

China 简体中文

  • 主题
  • 插件
  • 新闻
    • 文档
    • 论坛
  • 关于
  • 获取 WordPress
获取 WordPress
WordPress.org

Plugin Directory

Avatarly

  • 提交插件
  • 我的收藏
  • 登录
  • 提交插件
  • 我的收藏
  • 登录

Avatarly

作者:saumya010
下载
  • 详情
  • 评价
  • 安装
  • 开发进展
支持

描述

Avatarly adds a local, self-hosted avatar system to WordPress. Users can upload a profile picture directly on your site instead of relying on Gravatar, and site owners get full control over who’s allowed to upload, how avatars look, and where uploads are permitted.

Three ways to let users manage their avatar on the front end:

  • Shortcode — [avatarly]
  • Widget — add the “Avatarly (Legacy)” widget to any sidebar (classic, non-block themes)
  • Gutenberg block — search for “Avatarly” in the block inserter

Avatars can also always be managed from the standard WordPress Edit Profile screen.

Key features

  • Local avatar storage — no data sent to Gravatar unless you choose to keep it as a fallback.
  • Drag-and-drop / AJAX upload on the front end (progressively enhanced; falls back to a normal form for no-JS visitors).
  • Built-in crop and reposition popup: drag to pan and use the zoom slider to frame the shot before saving, or skip it to use the automatic center crop.
  • Strict upload validation: real MIME/extension checks, image verification, and file-size limits — not just a filename blacklist.
  • Automatic EXIF/GPS metadata stripping from uploaded images.
  • Fine-grained permissions: restrict uploads by capability and/or by specific roles.
  • A dedicated Styling tab: size, shape (circle/rounded/square), border, shadow, accent color, and button text.
  • Optional automatic cleanup of avatar files when a user account is deleted.
  • Translation ready.

Developer hooks

  • avatarly_avatar_size (filter) — change the avatar size used when generating a sized copy.
  • avatarly_avatar_data (filter) — filter the final avatar data array.
  • avatarly_avatar_html (filter) — filter the rendered <img> HTML.
  • avatarly_avatar_uploaded (action) — fires after a successful upload.
  • avatarly_avatar_deleted (action) — fires after an avatar is removed.

区块

该插件提供了 1 个区块.

  • Avatarly Lets the logged-in user upload or remove their local avatar.

安装

  1. Upload the avatarly folder to /wp-content/plugins/, or install it through the Plugins screen directly.
  2. Activate the plugin through the “Plugins” screen in WordPress.
  3. Visit Settings → Avatarly to configure permissions and styling.
  4. Add the [avatarly] shortcode to a page, add the “Avatarly (Legacy)” widget to a sidebar, or insert the “Avatarly” block wherever logged-in users need to manage their avatar.

常见问题

Does this replace Gravatar entirely?

No, by default it layers on top: if a user hasn’t uploaded a local avatar, WordPress falls back to Gravatar (or your configured default) as usual. You can disable that fallback in Settings → Avatarly → General & Permissions.

What image types are supported?

JPG, PNG, GIF, and WebP.

Can I choose which part of my photo is used?

Yes. When you select or drop an image, a crop popup lets you drag to reposition and zoom before saving. Selecting “Skip” uploads the image with an automatic center crop instead.

Can I restrict who is allowed to upload an avatar?

Yes. Under Settings → Avatarly → General & Permissions you can require the upload_files capability and/or restrict uploads to specific roles.

Where are avatar files stored?

In wp-content/uploads/avatarly/, following WordPress’s standard year/month upload structure.

What happens to avatar files if I delete a user?

By default nothing is deleted automatically. You can enable automatic cleanup on user deletion in the General & Permissions tab.

评价

此插件暂无评价。

贡献者及开发者

「Avatarly」是开源软件。 以下人员对此插件做出了贡献。

贡献者
  • saumya010

帮助将「Avatarly」翻译成简体中文。

对开发感兴趣吗?

您可以浏览代码,查看SVN仓库,或通过RSS订阅开发日志。

更新日志

1.0.3

  • Fixed the admin “Edit User” profile screen (e.g. an administrator uploading an avatar for another user) not saving a newly-selected avatar at all: the selected filename showed correctly in the field, but the page reloaded with no changes and no error. WordPress core’s own user-profile form doesn’t set enctype="multipart/form-data", since core itself has no file upload there — without it, the browser can’t actually send file data on submit. The form now correctly includes this attribute so avatar uploads on that screen work as expected.

1.0.2

  • Security hardening: the avatar uploads subfolder now writes its own .htaccess/index.php to deny script execution as a defense-in-depth measure, and the upload/delete REST endpoints are now rate-limited per user.

1.0.1

  • Removed the Custom CSS settings field. Per WordPress.org plugin guidelines, plugins may not let users save arbitrary custom CSS/JS/PHP; all supported styling (size, shape, border, shadow, accent color) is already exposed as dedicated controls in Settings → Avatarly → Styling.

1.0.0

  • Initial release, including a crop/reposition popup (drag to pan, zoom slider, skippable) for the front-end upload flow.

额外信息

  • 版本 1.0.3
  • 最后更新:3 周前
  • 活跃安装数量 不到10
  • WordPress 版本 6.3 或更高版本
  • 已测试的最高版本为 7.0.4
  • PHP 版本 7.4 或更高版本
  • 语言
    English (US)
  • 标签
    avatargravatarprofile pictureuploaduser profile
  • 高级视图

评级

尚未提交反馈。

您的评价

查看全部评论

贡献者

  • saumya010

支持

有话要说吗?是否需要帮助?

查看支持论坛

  • 关于
  • 新闻
  • 主机
  • 隐私
  • 陈列窗
  • 主题
  • 插件
  • 区块样板
  • 学习
  • 支持
  • 开发者
  • WordPress.tv ↗︎
  • 参与
  • 活动
  • 捐赠 ↗
  • 周边商品 ↗
  • WordPress.com ↗
  • Matt ↗
  • bbPress ↗
  • BuddyPress ↗
WordPress.org
WordPress.org

China 简体中文

  • 关注我们的 X(原 Twitter)账号
  • 访问我们的 Bluesky 账号
  • 关注我们的 Mastodon 账号
  • 访问我们的 Threads 账号
  • 访问我们的 Facebook 公共主页
  • 关注我们的 Instagram 账号
  • 关注我们的 LinkedIn 主页
  • 访问我们的 TikTok 账号
  • 访问我们的 YouTube 频道
  • 访问我们的 Tumblr 账号
代码如诗
The WordPress® trademark is the intellectual property of the WordPress Foundation.