woocommerce_transient_file_contents_served
Action that fires after a transient file has been successfully served, right before terminating the request.
Использование
add_action( 'woocommerce_transient_file_contents_served', 'wp_kama_woocommerce_transient_file_contents_served_action' ); /** * Function for `woocommerce_transient_file_contents_served` action-hook. * * @param array $transient_file_info Information about the served file, as returned by get_file_by_name. * * @return void */ function wp_kama_woocommerce_transient_file_contents_served_action( $transient_file_info ){ // action... }
- $transient_file_info(массив)
- Information about the served file, as returned by get_file_by_name.
Список изменений
С версии 8.5.0 | Введена. |
Где вызывается хук
woocommerce_transient_file_contents_served
woocommerce/src/Internal/TransientFiles/TransientFilesEngine.php 537
do_action( 'woocommerce_transient_file_contents_served', $file_name );