On product page when my customer is logged in what i want is that there shouldn't be a need for model to pop up to ask for email when user click on “notify me when available” button. It should directly add customer email from which account that he is logged in and add on the list.
Is there any way i can do that on shopify
Hi there,
I’m not aware of a way to do this with a pre-built/out-of-the-box solution; however, you would be able to do this programmatically by using Shopify’s liquid syntax to pre-fill the email address filed within the Back in Stock modal.
Here is a reference for Shopify’s liquid syntax.
You would essentially need to check if the customer is logged in by doing {% if customer %} and then you could access that customer’s email address via {{ customer.email }}. You would need to edit the Klaviyo/Shopify Back in Stock snippet to make this field pre-fill (if the customer is logged in).
Hope this helps. Someone else may have suggestions for a plugin or pre-built solution for this.
Best,
Caroline
What I want to know is how I can change the form because in the model it is just giving me labels and placeholders, not the actual form from where i can change the value input to the customer email.
Hi there,
You’re right that it’s not possible out of the box to edit the fields in that modal. Sorry for the confusion. Instead, you would need to create your own modal for Back in Stock and use the API endpoints described here to send the data to Klaviyo.
Best,
Caroline
Hi
Just wanted to follow up here -- were you able to create your own Back in Stock modal? Any other questions?
Best,
Caroline
Reply
Log in to the Community
Use your Klaviyo credentials
Log in with Klaviyo
Use your Klaviyo credentials
Log in with KlaviyoEnter your E-mail address. We'll send you an e-mail with instructions to reset your password.