Title: CDN Image Proxy
Author: Philip Newcomer
Published: <strong>2018 年 2 月 16 日</strong>
Last modified: 2018 年 2 月 16 日

---

搜索插件

**该插件尚未通过WordPress的最新3个主要版本进行测试**。 当与较新版本的WordPress一起
使用时，可能不再受到维护或支持，并且可能会存在兼容性问题。

![](https://s.w.org/plugins/geopattern-icon/cdn-image-proxy.svg)

# CDN Image Proxy

 作者：[Philip Newcomer](https://profiles.wordpress.org/philipnewcomer/)

[下载](https://downloads.wordpress.org/plugin/cdn-image-proxy.zip)

 * [详情](https://cn.wordpress.org/plugins/cdn-image-proxy/#description)
 * [评价](https://cn.wordpress.org/plugins/cdn-image-proxy/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/cdn-image-proxy/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/cdn-image-proxy/#developers)

 [支持](https://wordpress.org/support/plugin/cdn-image-proxy/)

## 描述

When developing locally, it’s common to use a database dump from a production site.
With large sites, it’s also common that the production site’s image uploads cannot
be easily copied to the local environment, because there are simply too many of 
them.

While local environments like [Pilothouse](https://github.com/Pilothouse-App/pilothouse)
allow you to easily proxy image uploads to your local environment from the production
site, that doesn’t work so well if you add or change one of the registered thumbnail
sizes in your local copy of the theme, since the new thumbnail size can’t be proxied
from production as it doesn’t exist there. You’re also not able to regenerate the
needed thumbnail sizes locally, because the original image file is not present locally.

_CDN Image Proxy_ solves this problem by using [Jetpack Image CDN](https://jetpack.com/support/photon/)(
formerly Photon) to proxy image uploads from your production site. Jetpack Image
CDN will automatically generate and serve any required thumbnail size on-the-fly,
but _CDN Image Proxy_ will tell it to look for the original image on your production
server, rather than on your local URL.

The result is that you can add or change registered image sizes locally whenever
you want, and Jetpack Image CDN will generate and provide a CDN URL for whatever
thumbnail size is required, sourced from the original image file located on the 
production site.

## 安装

 1. Install and activate _CDN Image Proxy_ on your local site
 2. Install and activate _Jetpack_ on your local site
 3. Go to `Settings > Media` and save your production site’s URL in the field provided.

You can also define your production site’s URL as a constant in `wp-config.php`,
like so:

    ```
    define( 'CDN_IMAGE_PROXY_REMOTE_URL', 'http://example.com' );
    ```

## 常见问题

  Installation Instructions

 1. Install and activate _CDN Image Proxy_ on your local site
 2. Install and activate _Jetpack_ on your local site
 3. Go to `Settings > Media` and save your production site’s URL in the field provided.

You can also define your production site’s URL as a constant in `wp-config.php`,
like so:

    ```
    define( 'CDN_IMAGE_PROXY_REMOTE_URL', 'http://example.com' );
    ```

  **I thought Jetpack Image CDN (Photon) doesn’t work on local sites, and required
a wordpress.com connection!**

That’s not a question, but _CDN Image Proxy_ will force the Jetpack Image CDN module
to be active on local sites, and will disable the wordpress.com connection requirement
for that module.

  **Are other magic image services supported besides Jetpack Image CDN (Photon)?**

Not at this time, but I’d be open to adding support for other services.

## 评价

此插件暂无评价。

## 贡献者及开发者

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

贡献者

 *   [ Philip Newcomer ](https://profiles.wordpress.org/philipnewcomer/)

[帮助将「CDN Image Proxy」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/cdn-image-proxy)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/cdn-image-proxy/)，查看
[SVN仓库](https://plugins.svn.wordpress.org/cdn-image-proxy/)，或通过[RSS](https://plugins.trac.wordpress.org/log/cdn-image-proxy/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/cdn-image-proxy/)。

## 更新日志

#### 1.0

 * Initial Release

## 额外信息

 *  版本 **1.0.0**
 *  最后更新：**8 年前**
 *  活跃安装数量 **不到10**
 *  WordPress 版本 ** 3.0 或更高版本 **
 *  已测试的最高版本为 **4.9.29**
 *  PHP 版本 ** 5.4 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/cdn-image-proxy/)
 * 标签
 * [cdn](https://cn.wordpress.org/plugins/tags/cdn/)[image](https://cn.wordpress.org/plugins/tags/image/)
   [jetpack](https://cn.wordpress.org/plugins/tags/jetpack/)[photon](https://cn.wordpress.org/plugins/tags/photon/)
   [proxy](https://cn.wordpress.org/plugins/tags/proxy/)
 *  [高级视图](https://cn.wordpress.org/plugins/cdn-image-proxy/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/cdn-image-proxy/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/cdn-image-proxy/reviews/)

## 贡献者

 *   [ Philip Newcomer ](https://profiles.wordpress.org/philipnewcomer/)

## 支持

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

 [查看支持论坛](https://wordpress.org/support/plugin/cdn-image-proxy/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](https://philipnewcomer.net/donate/)