/* Gör att både titel och term description hamnar i samma div. */
function custom_before() {
echo '<div class="textwrap">';
}
add_action('woocommerce_before_subcategory_title', 'custom_before');
/* För att lägga till samma div som ovan även för single products */
add_action('woocommerce_before_shop_loop_item_title', 'custom_before');
/* */
function custom_after($category) {
$cat_id = $category->term_id;
$prod_term = get_term($cat_id, 'product_cat');
$description = $prod_term->description;
if (is_shop()) :
echo '<div class="desc">' . $description . '</div></div>';
endif;
}
add_action('woocommerce_after_subcategory_title', 'custom_after');
function custom_aftertwo() {
global $product, $wpdb;
echo '<span class="sku"><strong>Art. no: </strong>' . $product->get_sku() . '</span>';
}
add_action('woocommerce_after_shop_loop_item_title', 'custom_aftertwo');
remove_action('woocommerce_after_shop_loop_item', 'woocommerce_template_loop_add_to_cart');
remove_action('woocommerce_after_shop_loop_item', 'woocommerce_template_loop_add_to_cart');