wc_after_switch_theme()
Attach functions that listen to theme switches.
No Hooks.
Returns
null. Nothing (null).
Usage
wc_after_switch_theme( $old_name, $old_theme );
- $old_name(string) (required)
- Old theme name.
- $old_theme(WP_Theme) (required)
- Instance of the old theme.
Changelog
| Since 9.7.0 | Introduced. |
wc_after_switch_theme() wc after switch theme code WC 10.6.2
function wc_after_switch_theme( $old_name, $old_theme ) {
wc_set_hooked_blocks_version_on_theme_switch( $old_name, $old_theme );
wc_update_store_notice_visible_on_theme_switch( $old_name, $old_theme );
}