Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // keep this code into functions.php
- // woocommerce support
- add_action( 'after_setup_theme', 'woocommerce_support' );
- function woocommerce_support() {
- add_theme_support( 'woocommerce' );
- }
- // Using hooks for woocommerce
- remove_action( 'woocommerce_before_main_content', 'woocommerce_output_content_wrapper', 10);
- remove_action( 'woocommerce_after_main_content', 'woocommerce_output_content_wrapper_end', 10);
- // Then hook in your own functions to display the wrappers your theme requires
- add_action('woocommerce_before_main_content', 'my_theme_wrapper_start', 10);
- add_action('woocommerce_after_main_content', 'my_theme_wrapper_end', 10);
- function my_theme_wrapper_start() {
- echo '<section id="main">';
- }
- function my_theme_wrapper_end() {
- echo '</section>';
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement