deprecated_class_run
Fires when a deprecated class is called.
Использование
add_action( 'deprecated_class_run', 'wp_kama_deprecated_class_run_action', 10, 3 ); /** * Function for `deprecated_class_run` action-hook. * * @param string $class_name The name of the class being instantiated. * @param string $replacement The class or function that should have been called. * @param string $version The version of WordPress that deprecated the class. * * @return void */ function wp_kama_deprecated_class_run_action( $class_name, $replacement, $version ){ // action... }
- $class_name(строка)
- The name of the class being instantiated.
- $replacement(строка)
- The class or function that should have been called.
- $version(строка)
- The version of WordPress that deprecated the class.
Список изменений
С версии 6.4.0 | Введена. |
Где вызывается хук
deprecated_class_run
wp-includes/functions.php 5698
do_action( 'deprecated_class_run', $class_name, $replacement, $version );