Forum Replies Created
-
AuthorPosts
-
I don’t know if its possible or not.
I have three product category. Men, Women, Kids. I wanted to show tags in these category pages. And it’s working Fine.
Now I want to show Sub- Category instead of tags here,( only in women, men, and kids). But when a user clicks on a subcategory it needs to show tags.
Is that possible?
Can we show the brand name only.
Currently its showing Brands: Dior. I want to show only Brand Name, Dior in this case.
Should I revert back the edited theme core file?
I hope I did it right … please let me know
Attachments:
You must be logged in to view attached files.I have several times cleared cache and face this issue … u need to scroll down at the beginning its good, then you will notice the problem. will try again a few times clearing cache and if it improves I will message u
Plus one more thing … can I have them clickable and it would take the user to the category they have clicked.
Plus, not sure if you understand this part also.
If a user selects “Dresses” … https://adikkt.com/fashion/women/womens-dresses/
then instead of saying Dresses, it will display there tags. Is this possible??
Thanks
as promised …
this is what they wrote …. I hope they did not add additional info while adding the code.
here it is …
Your theme don’t support standard hook action with woocommerce
https://docs.woocommerce.com/wc-apidocs/hook-docs.html
i have to Added some code in your theme in public_html/wp-content/themes/claue/core/libraries/vendors/woocommerce/templates/content-product.php line 136
HERE IS THE CODE:
global $post;
$id = $post->ID;
$brand = “”;if (get_option(‘pw_wooccommerce_display_brand_in_product_shop’) == “yes” || get_option(‘pw_woocommerce_image_brand_shop_page’) == “yes”) {
$terms = get_the_terms($post->ID, ‘product_brand’);
if (is_array($terms)) {
$brand .= ‘<span class=”pw_brand_product_list”>’;
if (get_option(‘pw_wooccommerce_display_brand_in_product_shop’) == “yes”) {$tax = get_option(‘pw_woocommerce_brands_text’, ”);
$brand .= ‘‘ . $tax . ‘‘;
if (is_array($terms)) {
$i = 0;
foreach ($terms as $b) {
$url = ”;
$url = esc_html(get_woocommerce_term_meta($b->term_id, ‘url’, true));
if ($url != ”) {
$brand .= ‘‘ . $b->name . ‘‘;
} else {
$brand .= ‘slug, ‘product_brand’) . ‘”>’ . $b->name . ‘‘;
}
if ($i < count($terms) – 1) {
$brand .= ‘, ‘;
}
$i++;
}
}
}
}if (get_option(‘pw_woocommerce_image_brand_shop_page’) == “yes”) {
$product_cats = wp_get_post_terms($post->ID, ‘product_brand’, array(“fields” => “ids”));$ratio = get_option(‘pw_woocommerce_image_brand_shop_page_image_size’, “150:150”);
list($width, $height) = explode(‘:’, $ratio);
foreach ($product_cats as $cat) {
$thumbnail = get_woocommerce_term_meta($cat, ‘thumbnail_id’, true);
if ($thumbnail) {
// $image = wp_get_attachment_thumb_url($thumbnail);
$image = current(wp_get_attachment_image_src($thumbnail, ‘full’));
$brand .= ‘‘;
}
}
}
$brand .= ‘</span>’;
}
echo $brand.'<br/>’;I hope it helps if you consider to add it to your theme.
Kemal
Yes, I did. Is there any plugin with which I can modify the code like we did with visual composer?
Check this website and check the menu. I want to do the same. You will see an image in the menu.
What code do I place??
-
AuthorPosts