Title: Customize Widgets Plus
Author: Weston Ruter
Published: <strong>2015 年 5 月 11 日</strong>
Last modified: 2015 年 6 月 3 日

---

搜索插件

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

![](https://s.w.org/plugins/geopattern-icon/customize-widgets-plus.svg)

# Customize Widgets Plus

 作者：[Weston Ruter](https://profiles.wordpress.org/westonruter/)

[下载](https://downloads.wordpress.org/plugin/customize-widgets-plus.zip)

 * [详情](https://cn.wordpress.org/plugins/customize-widgets-plus/#description)
 * [评价](https://cn.wordpress.org/plugins/customize-widgets-plus/#reviews)
 * [开发进展](https://cn.wordpress.org/plugins/customize-widgets-plus/#developers)

 [支持](https://wordpress.org/support/plugin/customize-widgets-plus/)

## 描述

This plugin consists of lab features and a testbed for improvements to Widgets and
the Customizer.

Requires PHP 5.3+.

**Development of this plugin is done [on GitHub](https://github.com/xwp/wp-customize-widgets-plus).
Pull requests welcome. Please see [issues](https://github.com/xwp/wp-customize-widgets-plus/issues)
reported there before going to the [plugin forum](https://wordpress.org/support/plugin/customize-widgets-plus).**

Current features:

#### Non-Autoloaded Widget Options

Widgets are stored in options (normally). Multi-widgets store all of their instances
in one big serialized array specific to that type. When there are many widgets of
a given type, the size of the serialized array can grow very large. What’s more 
is that `WP_Widget` does not explicitly `add_option(... 'no' )` before calling `
update_option()`, and so all of the settings get added with autoloading. This is
very bad when using Memcached Object Cache specifically because it can result in
the total `alloptions` cache key to become larger than 1MB and result in Memcached
failing to store the value in the cache. On WordPress.com the result is a [“Matt’s fault” error](https://github.com/Automattic/vip-quickstart/blob/master/www/wp-content/mu-plugins/alloptions-limit.php)
which has to be fixed by the VIP team. Widget settings should not be stored in serialized
arrays to begin with; each widget instance should be stored in a custom post type.
But until this is done we should stop autoloading options. See also [#26876](https://core.trac.wordpress.org/ticket/26876)
and [#23909](https://core.trac.wordpress.org/ticket/23909).

#### Widget Number Incrementing

Implements fixes for Core issue [#32183](https://core.trac.wordpress.org/ticket/32183)(
Widget ID auto-increments conflict for concurrent users). The stored widget_number
option provides a centralized auto-increment number for whenever a widget is instantiated,
even widgets in the Customizer that are not yet saved.

#### Efficient Multidimensional Setting Sanitizing

Settings for multidimensional options and theme_mods are extremely inefficient to
sanitize in Core because all of the Customizer settings registered for the subsets
of the `option` or `theme_mod` need filters that are added to the entire value, 
meaning sanitizing one single setting will result in all filters for all other settings
in that `option`/`theme_mod` will also get applied. This functionality seeks to 
improve this as much as possible, especially for widgets which are the worst offenders.
Implements partial fix for [#32103](https://core.trac.wordpress.org/ticket/32103).

#### HTTPS Resource Proxy

When `FORCE_SSL_ADMIN` is enabled (such as on WordPress.com), the Customizer will
load the site into the preview iframe using HTTPS as well. If, however, external
resources are being referenced which are not HTTPS, they will fail to load due to
the browser’s security model raise mixed content warnings. This functionality will
attempt to rewrite any HTTP URLs to be HTTPS ones via a WordPress-based proxy.

#### Widget Posts

Store widget instances in posts instead of options. Requires trunk due to patch 
committed in [#32474](https://core.trac.wordpress.org/ticket/32474). More details
forthcoming…

## 评价

此插件暂无评价。

## 贡献者及开发者

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

贡献者

 *   [ Weston Ruter ](https://profiles.wordpress.org/westonruter/)

[帮助将「Customize Widgets Plus」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/customize-widgets-plus)

### 对开发感兴趣吗?

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

## 更新日志

#### 0.2

Add Widget Posts module. See [changelog](https://github.com/xwp/wp-customize-widgets-plus/compare/0.1...0.2).

#### 0.1

Initial release.

## 额外信息

 *  版本 **0.2**
 *  最后更新：**11 年前**
 *  活跃安装数量 **10+**
 *  语言
 * [English (US)](https://wordpress.org/plugins/customize-widgets-plus/)
 * 标签
 * [customize](https://cn.wordpress.org/plugins/tags/customize/)[customizer](https://cn.wordpress.org/plugins/tags/customizer/)
   [widgets](https://cn.wordpress.org/plugins/tags/widgets/)
 *  [高级视图](https://cn.wordpress.org/plugins/customize-widgets-plus/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/customize-widgets-plus/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/customize-widgets-plus/reviews/)

## 贡献者

 *   [ Weston Ruter ](https://profiles.wordpress.org/westonruter/)

## 支持

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

 [查看支持论坛](https://wordpress.org/support/plugin/customize-widgets-plus/)