Hide “add to cart” & item counter

This topic has 8 replies, 2 voices, and was last updated 4 years, 1 months ago ago by Olga Barlow

  • Avatar: mohamed
    mohamed
    Participant
    May 25, 2021 at 15:19

    Hello Sir,

    All questions are in this single product page https://lithy.34way.com/ar/product/%d8%aa%d9%88%d9%8a%d9%88%d8%aa%d8%a7-%d9%83%d9%88%d8%b1%d9%88%d9%84%d8%a7/

    * Please we need to hide “add to cart” button and the item counter and “or” line separator and just keep “buy now” button, we tried to hide them by CSS but “buy now” disappear too! https://prnt.sc/13edha3

    * Also please, colors drop down list (the second list), how we can replace it by colors circles? not drop down list? or add colors circles to the drop down list? https://prnt.sc/13edjdg

    * Also, how we can translate “Buy Now” button and “Categories” word in the single product page?

    Thank You!

    Please, contact administrator
    for this information.
    7 Answers
    Avatar: Olga Barlow
    Olga Barlow
    Participant
    May 25, 2021 at 15:27

    Hello,

    1) Do you want to hide Add to cart button and q-ty and keep Buy now button only? Or you want to hide add to cart but keep q-ty and buy now button?

    2) Use variation swatches to change the select to colors https://youtu.be/LgzC4iK-j6A

    3) Translate XStore theme and also XStore core plugin https://www.8theme.com/documentation/xstore/theme-translation/base-theme-translation/

    Regards

    Avatar: mohamed
    mohamed
    Participant
    May 25, 2021 at 16:20

    Hello Olga,

    Thank You for your reply!

    1) we need to hide Add to cart button and q-ty and keep Buy now button only.

    2) variation swatches already active and then we updated “اختر اللون حتى تظهر خصائص الفئة المختارة” which is like “color” attribute in English to be color circle but it still appears in drop-down list! https://prnt.sc/13eg1xr

    3) will check link and follow steps

    4) is there any way we can make the 2 variants not related to each other? for example, we have “الفئة” variant “M/T new shape1.6 – 2021” and this variant not has color assigned to it in the product’s back-end and there is small description for this variant, but this discretion not appear if we choose only the variant from the first drop-down list, it appears only when we chose color too in the second drop-down list which already not added to this variant https://prnt.sc/13egdmk

    Thank You!

    Avatar: Olga Barlow
    Olga Barlow
    Participant
    May 25, 2021 at 16:46

    Hello,

    You are welcome.
    1) Add the below code to Theme Options > Custom CSS

    .single-product .et-or-wrapper, .single-product div.quantity, .single-product .single_add_to_cart_button.button:not(.et-single-buy-now) {
        display: none !important;
    }

    2) Use Latin characters for the attribute slug https://prnt.sc/13eh8ww and also for the terms slugs. I suppose your language in the slug field causes the issue.

    4) This is how the WooCommerce plugin works, we can do nothing with this.

    Regards

    Avatar: mohamed
    mohamed
    Participant
    May 26, 2021 at 14:25

    Hello Olga,

    We followed your recommendation about Attributes and Terms slug and issue is fixed 🙂

    There is just 2 other issues (one remaining and one new):

    1) about translating the XStore core, the link you sent is for loco translate, we use polylang plugin (theme is compatible with it as mentioned in theme preview). So how we can translate the core by polylang please?

    2) we tried to upload our logo but it not appear once we publish the update! should it be in specific dimensions (width and height)?

    Thank You!

    Avatar: Olga Barlow
    Olga Barlow
    Participant
    May 27, 2021 at 08:36

    Hello,

    1) Did you read Polylang documentation? https://polylang.pro/doc/how-to-translate-the-themes-and-plugins-hardcoded-strings/
    It requires translation files and they recommend translating hardcoded strings using Loco Translate. So, please, follow the docs and translate XStore theme and XStore core plugin using Loco translate first.

    2) Because it was uploaded via http but your site is https and logo is blocked https://gyazo.com/ea8b5a06bd7de3912c35017264b2ab66
    I have installed Really simple SSL plugin to fix the problem. Check now.

    Regards

    Avatar: mohamed
    mohamed
    Participant
    May 27, 2021 at 11:14

    Hello Olga,

    Thank You for your support 🙂

    * Logo issue is fixed, Thank You!

    * we installed loco translate plugin and followed instructions well, we checked XStore theme and plugin and translated “categories” word that appears in single product page, but it didn’t changed. So we checked WooCommerce plugin translation too, we found its all words already translated like “Categories” & “Buy Now” & “SKU” which all appears in single product page but non of them translated in the front end! https://lithy.34way.com/ar/product/%d8%aa%d9%88%d9%8a%d9%88%d8%aa%d8%a7-%d9%83%d9%88%d8%b1%d9%88%d9%84%d8%a7/

    Finally we tried to sync in loco translate but no luck so far!

    So, what is the problem now please?

    Thank You!

    Avatar: Olga Barlow
    Olga Barlow
    Participant
    May 27, 2021 at 13:18

    Hello,

    I checked your translation and don’t see that you translated buy now for example https://prnt.sc/13h8xsz
    So, make a double check that you translated all the necessary strings.

    Regards

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

The issue related to '‘Hide “add to cart” & item counter’' has been successfully resolved, and the topic is now closed for further responses

Helpful Topics

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