Skip to content

Instantly share code, notes, and snippets.

@nikolab
Created August 19, 2017 12:59
Show Gist options
  • Save nikolab/adfbc2ffd89c4d0ce21fb8c2a6e942ae to your computer and use it in GitHub Desktop.
Save nikolab/adfbc2ffd89c4d0ce21fb8c2a6e942ae to your computer and use it in GitHub Desktop.
remove_action( 'woocommerce_before_main_content', 'woocommerce_output_content_wrapper', 10);
remove_action( 'woocommerce_after_main_content', 'woocommerce_output_content_wrapper_end', 10);
function my_theme_wrapper_start() {
echo '<div id="primary" class="content-area">';
echo '<main id="main" class="site-main" role="main">';
}
function my_theme_wrapper_end() {
echo '</main>';
echo '</div>';
}
add_action('woocommerce_before_main_content', 'my_theme_wrapper_start', 10);
add_action('woocommerce_after_main_content', 'my_theme_wrapper_end', 10);
add_action( 'after_setup_theme', 'woocommerce_support' );
function woocommerce_support() {
add_theme_support( 'woocommerce' );
}
// change priority
remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_add_to_cart', 30);
add_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_add_to_cart', 6);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment