A cup of coffee
A heart set free

Auto WebP Image Optimizer

Auto WebP Image Optimizer 是一个强大的 WordPress 插件,用于自动将网站上的图片转换为 WebP 格式,显著提升网站加载速度并节省服务器空间。

Auto WebP Image Optimizer is a powerful WordPress plugin that automatically converts images on your website to WebP format, significantly improving website loading speed and saving server space.

插件特点 / Plugin Features

核心功能 / Core Features

  • 自动图片优化与格式转换:自动将上传的 JPEG、PNG、GIF 图片转换为 WebP 格式

  • 双重转换引擎:支持使用 GD 库或 Imagick 扩展进行转换

  • 完整缩略图处理:处理 WordPress 生成的所有缩略图尺寸

  • Automatic Image Optimization & Format Conversion: Automatically convert uploaded JPEG, PNG, and GIF images to WebP format

  • Dual Conversion Engine: Support conversion using GD library or Imagick extension

  • Complete Thumbnail Processing: Process all thumbnail sizes generated by WordPress

智能压缩策略 / Smart Compression Strategy

  • 基于文件大小的动态质量控制

    • 小文件(<200KB):默认 85% 质量
    • 中等文件(200KB-1MB):默认 80% 质量
    • 大文件(1MB-2.5MB):默认 75% 质量
    • 超大文件(>2.5MB):默认 70% 质量
  • File Size-Based Dynamic Quality Control

    • Small files (<200KB): Default 85% quality
    • Medium files (200KB-1MB): Default 80% quality
    • Large files (1MB-2.5MB): Default 75% quality
    • Extra large files (>2.5MB): Default 70% quality

图片处理功能 / Image Processing Features

  • 尺寸控制:可设置最大宽度和高度(默认 2048×2048 像素)

  • 文件过滤:可跳过小于 10KB 的文件

  • 透明度保持:正确处理 PNG 图片的透明背景

  • EXIF 清理:自动移除图片的 EXIF 数据

  • Size Control: Set maximum width and height (default 2048×2048 pixels)

  • File Filtering: Skip files smaller than 10KB

  • Transparency Preservation: Properly handle transparent backgrounds in PNG images

  • EXIF Data Removal: Automatically remove EXIF data from images

文件管理选项 / File Management Options

  • 原文件处理:可选择删除原文件以节省空间

  • 备份功能:可选择备份原始文件到专门目录

  • 批量转换:提供 WP-CLI 命令批量处理现有图片

  • Original File Handling: Option to delete original files to save space

  • Backup Functionality: Option to backup original files to a dedicated directory

  • Bulk Conversion: Provide WP-CLI commands for batch processing of existing images

管理界面 / Management Interface

  • 完整的后台设置页面

  • 启用/禁用转换功能

  • 配置不同文件大小的压缩质量

  • 设置图片尺寸限制

  • 查看转换统计信息(已转换图片数量、节省空间等)

  • Complete Backend Settings Page

  • Enable/Disable Conversion Functionality

  • Configure Compression Quality for Different File Sizes

  • Set Image Size Limits

  • View Conversion Statistics (number of converted images, saved space, etc.)

安装方法 / Installation Methods

方法 1:从 WordPress.org 安装(未来将支持) / Method 1: Install from WordPress.org (Coming Soon)

  1. 登录 WordPress 后台

  2. 进入「插件」→「添加新插件」

  3. 搜索「Auto WebP Image Optimizer」

  4. 点击「立即安装」,然后「启用插件」

  5. Log in to your WordPress admin dashboard

  6. Navigate to "Plugins" → "Add New"

  7. Search for "Auto WebP Image Optimizer"

  8. Click "Install Now", then "Activate Plugin"

方法 2:手动安装 / Method 2: Manual Installation

  1. 下载插件的 ZIP 文件

  2. 登录 WordPress 后台

  3. 进入「插件」→「添加新插件」→「上传插件」

  4. 选择下载的 ZIP 文件,点击「现在安装」

  5. 安装完成后,点击「启用插件」

  6. Download the plugin’s ZIP file

  7. Log in to your WordPress admin dashboard

  8. Navigate to "Plugins" → "Add New" → "Upload Plugin"

  9. Select the downloaded ZIP file and click "Install Now"

  10. After installation is complete, click "Activate Plugin"

使用说明 / Usage Instructions

基本设置 / Basic Settings

安装并启用插件后,您可以在 WordPress 后台的「设置」→「WebP 图片优化器」页面中配置插件选项。

After installing and activating the plugin, you can configure plugin options in the WordPress admin dashboard under "Settings" → "WebP Image Optimizer".

  1. 启用转换:勾选此选项启用自动 WebP 转换功能

  2. 压缩质量设置:根据文件大小设置不同的压缩质量

  3. 高级设置

    • 最大宽度/高度:设置图片的最大尺寸限制
    • 删除原始文件:转换后是否删除原始图片文件(谨慎使用)
    • 备份原始文件:是否备份原始图片到单独目录
    • 跳过小文件:是否跳过小于 10KB 的图片文件
    • 清理 EXIF 数据:是否移除图片中的 EXIF 元数据
  4. Enable Conversion: Check this option to enable automatic WebP conversion

  5. Compression Quality Settings: Set different compression qualities based on file size

  6. Advanced Settings:

    • Maximum Width/Height: Set maximum size limits for images
    • Delete Original Files: Whether to delete original image files after conversion (use with caution)
    • Backup Original Files: Whether to backup original images to a separate directory
    • Skip Small Files: Whether to skip images smaller than 10KB
    • Remove EXIF Data: Whether to remove EXIF metadata from images

批量转换现有图片 / Batch Convert Existing Images

插件提供了 WP-CLI 命令,用于批量转换网站上已有的图片。

The plugin provides WP-CLI commands for batch converting existing images on your website.

  1. 转换指定数量的图片

    wp awio convert --limit=100
  2. 强制重新转换所有图片

    wp awio convert --force
  3. 转换特定类型的图片

    wp awio convert --type=jpg,png
  4. 转换特定尺寸的图片

    wp awio convert --size=full,medium,thumbnail
  5. 查看转换统计信息

    wp awio stats
  6. Convert a specific number of images:

    wp awio convert --limit=100
  7. Force re-convert all images:

    wp awio convert --force
  8. Convert specific types of images:

    wp awio convert --type=jpg,png
  9. Convert specific sizes of images:

    wp awio convert --size=full,medium,thumbnail
  10. View conversion statistics:

    wp awio stats

系统要求 / System Requirements

  • WordPress 5.0 或更高版本

  • PHP 7.0 或更高版本

  • 以下任一图片处理库:

    • GD 库(推荐 2.0 或更高版本)
    • Imagick 扩展
  • WordPress 5.0 or higher

  • PHP 7.0 or higher

  • Either of the following image processing libraries:

    • GD library (version 2.0 or higher recommended)
    • Imagick extension

作者信息 / Author Information

作者:dashen.wang
主页:https://dashen.wang

Author: dashen.wang
Website: https://dashen.wang

 

评论 抢沙发

登录

找回密码

注册