Created
September 28, 2020 11:56
-
-
Save yousufansa/718220365ae799e88b65355b2514aaee to your computer and use it in GitHub Desktop.
Bookworm - Display Header v1 Topbar Cart on Mobile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if ( ! function_exists( 'bw_child_site_header_icons_wc_cart_args' ) ) { | |
| function bw_child_site_header_icons_wc_cart_args( $links ) { | |
| if ( isset( $links['my_cart'] ) ) { | |
| $links['my_cart']['item_class'] = 'd-block'; | |
| } | |
| return $links; | |
| } | |
| } | |
| if ( ! function_exists( 'bw_child_topbar_display_wc_cart_header_v1_mobile' ) ) { | |
| function bw_child_topbar_display_wc_cart_header_v1_mobile() { | |
| add_filter( 'bookworm_site_header_icons_links', 'bw_child_site_header_icons_wc_cart_args', 20 ); | |
| } | |
| } | |
| add_action( 'bookworm_header_v1', 'bw_child_topbar_display_wc_cart_header_v1_mobile', 5 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment