customize_save_{$this->id_data[‘base’]}
云策文档标注
概述
customize_save_{$this->id_data['base']} 是一个 WordPress 动态 Hook,在 WP_Customize_Setting::save() 方法被调用时触发,用于自定义设置保存操作。
关键要点
- 这是一个动态 Hook,其名称中的 $this->id_data['base'] 部分指代设置名称的基础 slug。
- Hook 的参数是 $this,即 WP_Customize_Setting 实例。
- 该 Hook 自 WordPress 3.4.0 版本引入。
原文内容
Fires when the WP_Customize_Setting::save() method is called.
Description
The dynamic portion of the hook name, $this->id_data['base'] refers to the base slug of the setting name.
Parameters
$thisWP_Customize_Setting-
WP_Customize_Setting instance.
Source
if ( empty( self::$aggregated_multidimensionals[ $this->type ][ $id_base ]['previewed_instances'] ) ) {
Changelog
| Version | Description |
|---|---|
| 3.4.0 | Introduced. |