| 开发者 | razvanccyis |
|---|---|
| 更新时间 | 2026年10月9日 21:22 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 7.1 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
wp_get_attachment_url, featured images, block editor, REST API) to point at the YourImageShare-hosted file - including images and videos already placed in posts before they were offloadedwp yis offload --all, not just new uploads - a Media Library that's already full is the actual reason most people install a plugin like thissrcset (thumbnail and full size) instead of
WordPress's usual list of sizes, and image sizes wider than 280 px are
served from the full file. Hard-cropped sizes (such as a square
thumbnail) keep the image's own proportions.
Free API key required
You'll need a free YourImageShare account and an Upload-only API key
(this plugin's settings page links straight to it). No account is
required to use YourImageShare itself, but an account is what gives you
an API key.
Yes. Offloaded media resolves through WordPress's normal attachment functions, so it works anywhere an attachment is used: the block editor, Add Media, featured images, galleries, REST API responses.
They're left alone until you choose to offload them. Use the Offload
existing media button on the plugin's settings page to process your
whole existing library in the background (WP-Cron), respecting the API's
rate limits - you can close the page while it runs. On the command line,
wp yis offload --all does the same. New uploads offload automatically
either way.
The Upload-only key allows 2,000 uploads a day and 20 a minute. The background run pauses by itself when a limit is reached and continues when it resets.
Yes. Every offloaded file has a Restore to local action (Media Library row actions, or the attachment details panel) that downloads it back to your server and clears the offload status - WordPress treats it as a completely normal local attachment again afterward.
The settings page asks for your Upload-only key specifically, not your main API key - it can only upload on your behalf, never list or delete your account's uploads. The optional full API key (only needed if you turn on remote deletion, or choose to delete a remote copy while restoring) has more access, so only add that one if you actually want that behavior.
The local file is left exactly as WordPress created it - nothing is deleted unless the remote upload is confirmed successful first. Failures show up as a dismissible notice on the Media Library and plugin settings screens with the reason, rather than failing silently.
wp yis status, wp yis offload --all|<id>..., wp yis restore <id>....