Support » Plugin: WooCommerce » How do I change the template directory for each WOOCOMMERCE VERSION

  • t.nonaka

    (@tnonaka)


    Hi there.

    I want to use different templates depending on the user wc version.

    I wrote the following function on functions.php, but override template did not changed.
    if ( version_compare( WOOCOMMERCE_VERSION, “2.1” ) >= 0 ) {
    function my_template_path() {
    return ‘woocommerce-2.1.x/’;
    }
    add_filter(‘WC_TEMPLATE_PATH’ , ‘my_template_path’);
    }
    Please help me. thank you.

    https://wordpress.org/plugins/woocommerce/

  • The topic ‘How do I change the template directory for each WOOCOMMERCE VERSION’ is closed to new replies.