WP_Block_Editor_Context::__construct()
Constructor.
Populates optional properties for a given block editor context.
Метод класса: WP_Block_Editor_Context{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$WP_Block_Editor_Context = new WP_Block_Editor_Context(); $WP_Block_Editor_Context->__construct( $settings );
- $settings(массив)
- The list of optional settings to expose in a given context.
По умолчанию: array()
Список изменений
С версии 5.8.0 | Введена. |
Код WP_Block_Editor_Context::__construct() WP Block Editor Context:: construct WP 6.7.2
public function __construct( array $settings = array() ) { if ( isset( $settings['name'] ) ) { $this->name = $settings['name']; } if ( isset( $settings['post'] ) ) { $this->post = $settings['post']; } }