Show Brand Name on Shop Page - by slidebird

This topic has 12 replies, 2 voices, and was last updated 6 years, 9 months ago ago by Laranz

  • Avatar: slidebird
    slidebird
    Participant
    June 25, 2017 at 16:00

    Hi

    I was wondering if its possible to show the brand Name (if selected on the productpage of course) on the products grid on the shop page… at the moment it shows only the product categories

    thanks 4 help

    11 Answers
    Avatar: laranz
    Laranz
    Participant
    June 26, 2017 at 05:17

    Hi,

    Download this file and unzip it: http://take.ms/8imKv . If you don’t have a child theme create one, then create a folder named woocommerce in it, and then add this file content-single-product.php in to that folder, it will do. It add the brands next to the categories in the single product page.

    Let us know,

    Thanks,
    laranz.

    Avatar: slidebird
    slidebird
    Participant
    June 26, 2017 at 08:58

    oK THANKS this works but that was not my intention… i do not show the categories on the single product page anyway…

    i want to show the brand on the main shop page.. see here http://prntscr.com/fo7vwn

    is this possible as well?

    thanks for your great and quick support

    Avatar: laranz
    Laranz
    Participant
    June 26, 2017 at 09:53

    Hi,

    Can you show us your website address? It is little customization, but I can guide you. 🙂

    Let us know,

    Thanks,
    laranz.

    Avatar: slidebird
    slidebird
    Participant
    June 26, 2017 at 09:58

    oh great

    http://www.max-schmuckdesign.com/shop/

    as you can see i set the value of the “product-page-cats” to display:none altough i just saw there is a theme option for that…

    so it would be great that only the brand will be shown on this site … im familiar with hmtl, css and a little bit php… child theme is installed of course

    thanks a lot

    Avatar: laranz
    Laranz
    Participant
    June 26, 2017 at 11:10

    Hi,

    Use this content-product.php inside your woocommerce folder in the child theme, I edited the line #183 to #196 you can edit it according to your needs, you can also move that part to anywhere you want.

    Let us know,

    Thanks,
    laranz.

    Avatar: slidebird
    slidebird
    Participant
    June 26, 2017 at 11:22

    ok great but where is the file? there was no link in the message

    thanks

    Avatar: laranz
    Laranz
    Participant
    June 26, 2017 at 12:17

    Hi,

    Sorry for the inconvenience caused, I forget to paste the link for the file, here it is: http://take.ms/1aIWI

    Let us know,

    Thanks,
    laranz.

    Avatar: slidebird
    slidebird
    Participant
    June 26, 2017 at 12:41

    Ok worked great…

    But two small questions… where does this comma after the brandname come from? because we always have only one brand so the comma makes no sense… and i cant find the translation for “brands” … there is one in the legenda theme de_DE.po file but it has no impact on the frontend…

    thanks for the great support

    Avatar: laranz
    Laranz
    Participant
    June 27, 2017 at 06:02

    Hi,

    1. I added the comma in the line #192 of content-product.php

    echo ‘‘ . $term->name . ‘,’;

    remove that.

    2. You need to recreate the .po file using POEdit or edit the Brand name directly in line#186 of the same file.

    Let us know,

    Thanks,
    laranz.

    Avatar: slidebird
    slidebird
    Participant
    June 27, 2017 at 07:30

    Awsome thank you so much

    Avatar: laranz
    Laranz
    Participant
    June 27, 2017 at 07:53

    Hi,

    Glad we helped. 🙂 If you’re happy with our service don’t forget to rate our theme. 🙂

    Let us know if you have any other questions,

    Thanks,
    laranz.

  • Viewing 12 results - 1 through 12 (of 12 total)

You must be logged in to reply to this topic.Log in/Sign up

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.