WC_Admin_Addons::filter_admin_body_classes()
We're displaying page=wc-addons and page=wc-addons§ion=helper as two separate pages. When we're on those pages, add body classes to distinguishe them.
Метод класса: WC_Admin_Addons{}
Хуков нет.
Возвращает
Строку
. Body class with added class for Marketplace or My Subscriptions page.
Использование
$result = WC_Admin_Addons::filter_admin_body_classes( $admin_body_class ): string;
- $admin_body_class(строка)
- Unfiltered body class.
По умолчанию: ''
Код WC_Admin_Addons::filter_admin_body_classes() WC Admin Addons::filter admin body classes WC 9.3.1
public static function filter_admin_body_classes( string $admin_body_class = '' ): string { if ( isset( $_GET['section'] ) && 'helper' === $_GET['section'] ) { return " $admin_body_class woocommerce-page-wc-subscriptions "; } return " $admin_body_class woocommerce-page-wc-marketplace "; }