Ticker

6/recent/ticker-posts

Header Ads Widget

Shared Hosting with Namecheap. Free .Website domain & WhoisGuard

Notify me when product is available notification in shopify

It is very important for an ecommerce store to keep track of the products liked by their customers and make the customer aware when the products are back in stock. If you are not using backorders for your products, you need to inform your customers manually about the re-stocked items. However how would you know which product is like by which customer? or which customer is willing to make a purchase when the product of their choice is back in stock?

Well the solution is simple. Use a custom contact form on the product page that collects customers email and send the admin details of the customers email address along with their product choice.

open the product.liquid file and paste the below code at the position where you would like to show the option to customers to put their email address.


 {% unless product.available %}  
 <div id="sold-out">  
  {% form 'contact' %}  
   {% if form.posted_successfully? %}  
   <p class="accent-text">Thanks! We will notify you when this product becomes available!</p>  
   {% else %}  
   <p>Click <a id="notify-me" href="#"><strong>here</strong></a> to be notified by email when {{ product.title }} becomes available.</p>  
   {% endif %}  
   {% if form.errors %}  
   <div class="error feedback accent-text">  
    <p>Please provide a valid email address.</p>  
   </div>  
   {% endif %}  
   {% unless form.posted_successfully? %}  
   <div id="notify-me-wrapper" class="clearfix" style="display:none">  
    {% if customer %}  
    <input type="hidden" name="contact[email]" value="{{ customer.email }}" />  
    {% else %}  
    <input style="float:left; width:180px;" required="required" type="email" name="contact[email]" placeholder="your@email.com" class="styled-input{% if form.errors contains 'email' %} error{% endif %}" value="{{ contact.fields.email }}" />  
    {% endif %}  
    <input type="hidden" name="contact[body]" value="Please notify me when {{ product.title | escape }} becomes available." />  
    <input style="float:left; margin-left:5px;" class="btn styled-submit" type="submit" value="Send" />       
   </div>  
   {% endunless %}  
   <script>  
   jQuery('#notify-me').click(function() {   
    {% if customer %}  
    jQuery('#sold-out form').submit();   
    {% else %}        
    jQuery('#notify-me-wrapper').fadeIn();        
    {% endif %}  
    return false;  
   } );  
   </script>  
  {% endform %}  
 </div>  
 {% endunless %}  

This tweak was taken from shopify official website. However they have removed this post since many developers have developed apps to include this functionality. You can either use this code or go for an app. Choice is yours.

Post a Comment

6 Comments

  1. That's a hack. This will help to regain customer confidence in our stores.

    Btw, Would you be interested in write a review on Shopify Inventory Management Extension?

    ReplyDelete
  2. i like it ,this way it will increase the confidence between the seller and the customer.

    ReplyDelete
  3. SHOPIFY search system being more friendly and reliable. Just the price is matter.

    ReplyDelete
  4. Google
    Good Product. Thanks for Shearing. I want to buy it . Please tale me more about the Product.i like it very much

    ReplyDelete