• Resolved lamayas

    (@lamayas)


    Hello,

    I am trying to set up required registration for some of my products while maintaining guest checkout for others. Looked into it and used this snippet for that.

    The thing is, for products that do require registration, users just get a message that says ‘you have to login before purchasing’, without any way to actually login or register.

    Is there any way to change this within Woocommerce? I mean change the message or show users an option to register.

    Thanks for any help.

    • This topic was modified 1 year, 11 months ago by lamayas.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Hi @lamayas ,

    Thanks for reaching out!

    While custom code is outside our scope of support, I have tested the code snippet you are using, and I see what you mean:

    I tested further and it appears that there are a few settings within WooCommerce → Settings → Account and Privacy that need to be adjusted for this to work as you require.

    Please can you change the options within WooCommerce → Settings → Account and Privacy to exactly as what is displayed in the screenshot below and see if this is what you are wanting to achieve:

    Hope this helps!

    Thread Starter lamayas

    (@lamayas)

    Hi, Roxy

    I appreciate you checking it out! I don’t think this will achieve what I’m looking for though, since it will make registration optional at checkout.

    What I would like is to offer users the option to register before checkout but only for a couple products. I just don’t see how to edit the message that’s showing or include a registration form there since that’s technically part of the checkout.

    Thanks for your help.

    Hi @lamayas ,

    Thanks for providing an update!

    I appreciate you checking it out! I don’t think this will achieve what I’m looking for though, since it will make registration optional at checkout.

    To clarify, when testing the code on my end, and the Account and Privacy options are set as in the previous screenshot, creating an account is required (not optional) on checkout, for products not marked as “Allow guest checkout”, as seen below:

    Product with “Allow Guest Checkout” enabled:

    Product that requires registration:

    What I would like is to offer users the option to register before checkout but only for a couple products. I just don’t see how to edit the message that’s showing or include a registration form there since that’s technically part of the checkout.

    This may require custom code which is outside our scope of support.

    While I do not know of any plugin or custom code that can help you achieve exactly this, you could look at?hiring a developer?or ask your customisation questions in one of the channels below.

    Hope this points you in the right direction ??

    Thread Starter lamayas

    (@lamayas)

    Thank you! This is a great workaround.

    One more thing though, for products that allow guest checkout I do still see the checkbox that says Create an account? It’s optional but still, any way to hide it in that case?

    Thanks again for your help.

    Hi @lamayas ,

    Happy to help ??

    One more thing though, for products that allow guest checkout I do still see the checkbox that says Create an account? It’s optional but still, any way to hide it in that case?

    This would require custom code which, as previously mentioned, is outside our scope of support.

    However, I will leave this open for a bit to see if anyone may be able to chime in to help you out with this.

    Alternatively, you can look at hiring a developer.

    Cheers!

    The CSS below will remove the “Create An Account” checkbox option at the checkout page

    .woocommerce-form__label.woocommerce-form__label-for-checkbox.checkbox{
    display: none;
    }

    Go to Appearance -> Customize -> Additionnal CSS and paste the CSS there

    Hope this helps

    Cheers !

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Allow Guest Checkout on certain products with registration option’ is closed to new replies.