Trying to get “Related Products” to work

7 replies3 participantsUpdated by Rose Tyler

  • Avatar: Su Flo
    Su Flo
    Participant

    Information and screenshot in Private Content Section.

    Please, contact administrator
    for this information.

    7 Answers

    Avatar: Olga Barlow
    Olga Barlow
    Participant

    Hello,

    Due to WC plugin docs

    Related Products is a section on some templates that pulls products from your store that share the same tags or categories as the current product.

    https://docs.woocommerce.com/document/related-products-up-sells-and-cross-sells/#section-3
    All products from your screenshot have the same tag, that’s why you see them as related products.

    If you don’t want to show these products and want to choose what products to show then I would suggest you to disable related products in Theme Options and enable Upsells (change position of up-sell products from “sidebar” to “After content”).

    Regards

    Avatar: Su Flo
    Su Flo
    Participant

    Hi Olga,

    Have done that and it seems to work, thank you.

    One problem, underneath the selected product, it says “OUR OFFERS”, How can we change this to “RELATED PRODUCTS”

    Printscreen in private content box.

    Please, contact administrator
    for this information.
    Avatar: Rose Tyler
    Rose Tyler
    Support staff

    To avoid editing of php files I would recommend using translation files to change it. Use Loco Translate plugin https://www.8theme.com/demo/docs/xstore/#translation , create English translation and just change necessary strings to what you need.

    Regards

    Avatar: Su Flo
    Su Flo
    Participant

    Hi Rose,

    Instead of adding the plugin, can we change the wording to “related items” instead? Also, would there be any problems if we changed “OUR OFFERS” to “RELATED PRODUCTS” in the php?

    Avatar: Rose Tyler
    Rose Tyler
    Support staff

    You may find this text in xstore/woocommerce/single-product/up-sells.php file.
    Please note you need to make changes in the child theme https://codex.wordpress.org/Child_Themes so the modifications won’t be lost after theme update.
    Create the same directory in child theme like xstore-child/woocommerce/single-product and copy the file up-sells.php there and edit it.

    Regards

    Avatar: Su Flo
    Su Flo
    Participant

    Hi Rose,

    We are having big difficulties as to what we should be cutting and pasting and to exactly where.

    Is it possible to advise as to where we can find the child theme location to paste into the theme, and also exactly what needs to be pasting.

    Hope you can advise. Kind Regards, Su.

    Please, contact administrator
    for this information.
    Avatar: Rose Tyler
    Rose Tyler
    Support staff

    You need copy up-sells.php file from your parent theme, then go to child theme > create woocommerce empty folder and inside create single-product folder, then add in this folder up-sells.php file. After that, you may edit “OUR OFFERS” text in up-sells.php file of your child theme. Don’t forget to activate child theme on your site to be able to see an effect of your changes.
    Please read documentation https://codex.wordpress.org/Child_Themes.

    Regards

Want to reply? Log in, or register with your ThemeForest purchase code, to reply to this topic.

Login / Register