This file contains 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
<?php | |
// Output variations as a list so they look like a single product | |
// Works in theme/woocommerce/single-product/add-to-car/variable.php | |
?> | |
<table class="table table-striped table-hover"> | |
<thead> | |
<tr> | |
<th>Ref #</th> | |
<?php foreach ( $attributes as $name => $options) :?> | |
<th><?php echo $woocommerce->attribute_label($name); ?></th> |
This file contains 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
<?php | |
$current_tax = get_query_var( 'product_cat' ); | |
$term =get_term_by( 'slug', $current_tax, 'product_cat'); | |
$term_name = $term->name; | |
$term_id = $term->term_id; | |
?> |
This file contains 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
// Paste this in to your theme's functions file | |
// Redefine sub category display to output empty categories | |
function woocommerce_product_subcategories( $args = array() ) { | |
global $woocommerce, $wp_query, $_chosen_attributes; | |
$defaults = array( | |
'before' => '', | |
'after' => '', | |
'force_display' => false | |
); |
NewerOlder