global $product;
$meta_values = get_post_meta($product->post->ID);
if(!$meta_values['wfg_single_gift_enabled']) {
$gift_id = $meta_values["_wfg_single_gift_products"];
$session_data = (unserialize($gift_id[0]));
echo $session_data[0];
}
$itemcat = $item->title;
$taxonomy = 'product_cat';
$empty = 0;
$args = array(
'taxonomy' => $taxonomy,
'hide_empty' => $empty
);
$all_categories = get_categories( $args );
foreach ($all_categories as $cat) {
$category_name = $cat->name;
if($category_name==$itemcat) {
$cat_name = $category_name;
$category_id = $cat->term_id;
$thumbnail_id = get_woocommerce_term_meta( $category_id, 'thumbnail_id', true );
$cat_image = wp_get_attachment_url( $thumbnail_id );
$description = $cat->description;
}
}
if ( ! function_exists( 'woocommerce_mini_cart' ) ) {
/**
* Output the Mini-cart - used by cart widget
*
*/
function woocommerce_mini_cart( $args = array() ) {
$defaults = array(
'list_class' => ''
);
$args = wp_parse_args( $args, $defaults );
wc_get_template( 'cart/mini-cart.php', $args );
}
}