Automattic\WooCommerce\Internal\Admin\Settings
SettingsUIRequestContext::get_context_key
Get the context cache key.
Метод класса: SettingsUIRequestContext{}
Хуков нет.
Возвращает
string.
Использование
$result = SettingsUIRequestContext::get_context_key( $settings_page, $section ): string;
- $settings_page(WC_Settings_Page) (обязательный)
- Settings page.
- $section(строка) (обязательный)
- Section id. Empty string means the default section.
Код SettingsUIRequestContext::get_context_key() SettingsUIRequestContext::get context key WC 11.2.2
private static function get_context_key( \WC_Settings_Page $settings_page, string $section ): string {
return implode(
'::',
array(
(string) spl_object_id( $settings_page ),
$settings_page->get_id(),
self::get_section_key( $section ),
)
);
}