Hello,
Try to add the below code to the child theme’s functions.php file and check it works or not –
function owp_off_canvas_filter_button() {
$text = get_theme_mod( 'ocean_woo_off_canvas_filter_text' );
$text = oceanwp_tm_translation( 'ocean_woo_off_canvas_filter_text', $text );
$text = $text ? $text: esc_html__( 'Filter', 'oceanwp' );
$output = '<a href="#" class="oceanwp-off-canvas-filter"><i class="icon-menu"></i><span class="off-canvas-filter-text">'. esc_html( $text ) .'</span></a>';
echo $output;
}
add_action( 'woocommerce_before_shop_loop','owp_off_canvas_filter_button', 10 );
It didn’t work.
The code added one more Filter button on /shop page.
Image: https://gyazo.com/7dcc8589899aa36f84ab9a1671483185
What I want is: I want “Filter” button to be on all categorized pages.
If I go to http://www.website.com/t-shirts, there I want to see Filter button with Tshirt options.
I want to display here: https://gyazo.com/1c2857015abbf0e52840a857f3ed6940
-
This reply was modified 6 years, 3 months ago by
skllmyh.