Solved

Back in Stock Flow does not populate the Product

  • 11 February 2022
  • 1 reply
  • 266 views

Badge +2

 I am setting up a back in stock flow for my BigCommerce website. I added the script and it has collected emails. Below are the 2 issues I am having with the back in stock flow and script.

  1. The “notify me when available” button appears on one product that is out of stock but not another that is similar. Everything on the back end is the exact same for these two products, yet the green one does not show the “notify me when available” button. Below is my script code (without account information).

    <script src="https://a.klaviyo.com/media/js/onsite/onsite.js"></script>
    <script>
         var klaviyo = klaviyo || [];     
         klaviyo.init({   
              account: '',
              list: '',
              platform: 'bigcommerce'
         });  
         klaviyo.enable("backinstock",{    
         trigger: {  
              product_page_text: "Notify Me When Available", 
              product_page_class: "button",  
              product_page_text_align: "center", 
              product_page_margin: "0px", 
              replace_anchor: false 
         },  
         modal: {   
              headline: "{product_name}",   
              body_content: "Subscribe to receive an email when this item is available for purchase.",   
              email_field_label: "Email",   
              button_label: "Notify me when available",   
              subscription_success_label: "You're in! We'll let you know when it's available.",  
              footer_content: '',  
              additional_styles: "@import url('https://fonts.googleapis.com/css?family=Helvetica+Neue');",   
              drop_background_color: "#000",  
              background_color: "#fff",  
              text_color: "#222",    
              button_text_color: "#fff",  
              button_background_color: "#CB9348",  
              close_button_color: "#ccc",   
              error_background_color: "#fcd6d7",   
              error_text_color: "#C72E2F",  
              success_background_color: "#d3efcd",  
              success_text_color: "#185d35",
              newsletter_subscribe_label: "Add me to your email list.",
              subscribe_checked: true
              } 
         });
    </script>

     

  2.  When I go to preview the email it shows “ Unable to find item with code: . It may have been deleted.” I am not sure if this is a preview issue or if the flow is not pulling the correct information.

 

icon

Best answer by thoyt 16 February 2022, 14:15

View original

1 reply

Badge +2

After speaking further with Klaviyo’s team they have explained that the issue was needing to select a color/size before the button would populate. Also, the flow would populate correctly after a product goes back in stock.

Reply