New In Sticker

This guide outlines the steps to add a "New In" sticker to products in your Shopify store using the Findify app. This feature will highlight new products added to your store within the last 30 days.

Steps to Implement the "New In" Sticker

Step 1: Configure created_at Field in Findify Merchant Dashboard

  1. Go to the Merchant Dashboard:
    • Navigate to Settings > Primary Setup > Filtering.
  2. Enable created_at Field:
    • Find the created_at field and ensure it is returned in the Liquid framework.

Step 2: Assign created_at Variable in Shopify Theme

  1. Navigate to Shopify Theme Editor:
    • Go to Online Store > Themes.
    • Click Actions > Edit Code for the theme you are using.
  2. Edit findify-product-connector.liquid File:
    • Locate and open the findify-product-connector.liquid file.
    • Add the following code to assign the created_at variable:
{% if query_parameters contains "created_at=" %}
  {% assign created_at = query_parameters | split: "created_at=" | last | split: "&" | first %}
{% endif %}

Step 3: Display the "New In" Sticker in Product Cards

  1. Edit findify-product-card.liquid File:
    • Locate and open the findify-product-card.liquid file.
    • Add the following code to calculate the time difference and display the "New In" sticker if the product was added within the last 30 days:
{% assign current_time = 'now' | date: "%s" | times: 1000 %}
{% assign time_difference = current_time | minus: created_at %}
{% assign days_difference = time_difference | divided_by: 1000 | divided_by: 60 | divided_by: 60 | divided_by: 24 %}

{% if days_difference < 30 %}
  <div class="findify-sticker">
    New In
  </div>
{% endif %}

Step 4: Add CSS for the Sticker

  1. Edit findify-product-card.css File:
    • Locate and open the findify-product-card.css file.
    • Add the following CSS to style the "New In" sticker:
.findify-sticker {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #fff;
  font-size: 12px;
  padding: 2px 4px;
  border-radius: 4px;
  color: #333;
  font-weight: bold;
}

Conclusion

By following these steps, you will successfully add a "New In" sticker to products that have been added to your store within the last 30 days. This will help highlight new products and potentially increase customer engagement and sales.

For further assistance or inquiries, feel free to contact us at [email protected].