woocommerce_session_handler
Filter to overwrite the session class that handles session data for users.
Usage
add_filter( 'woocommerce_session_handler', 'wp_kama_woocommerce_session_handler_filter' ); /** * Function for `woocommerce_session_handler` filter-hook. * * @param $string * * @return */ function wp_kama_woocommerce_session_handler_filter( $string ){ // filter... return $string; }
- $string
- -
Where the hook is called
woocommerce_session_handler
woocommerce_session_handler
woocommerce/includes/class-woocommerce.php 1049
$session_class = apply_filters( 'woocommerce_session_handler', 'WC_Session_Handler' ); // phpcs:ignore WooCommerce.Commenting.CommentHooks.MissingSinceComment
woocommerce/includes/wc-core-functions.php 2447
$session_class = apply_filters( 'woocommerce_session_handler', 'WC_Session_Handler' );