Automatically Apply a Customer Tag on Registration

Follow

Warning!

This is an unsupported theme customization. Please proceed with this guide at your own risk and/or contact your site developer for additional assistance.

Overview

Custom Pricing provides you with the ability to automatically apply a wholesale tag for a customer when they create an account. This ensures that they receive their wholesale pricing immediately.

This theme customization is useful if your primary customer base is wholesale clients or businesses and don't want to have to manually tag each of their accounts after registering.

Note: Your customer pricing tags should already be created before proceeding with this guide. As well, customer accounts should be enabled for your site.

To automatically add a customer tag on registration, please follow these steps:

  1. From Shopify's admin, select Online Store.

    Select the Online Store option from the left side of your Shopify admin

  2. Select Actions.

    Select the Actions button to the right of your theme name

  3. Select Edit code.

    Select Edit Code from the dropdown menu that appears after selecting the previous option

  4. Under "Templates", select customers/register.liquid.

    Select Templates, then the customers/register.liquid file

  5. Find:

    {% form 'create_customer' %}

    Find the form create customer line of code in this file

  6. Copy and paste this code directly below that line:

    Note: This code will add the tag "Wholesale" to any customer that registers. To use a different tag, replace "Wholesale" with the tag of your choice.

    <input type="hidden" id="customer_tags" name="customer[tags]" value="Wholesale"/>

    Copy and paste the input type line of code directly below the form create customer code

  7. Select Save.

    Select Save in the top right corner of the code editor

Helpful Links:

1 out of 1 found this helpful

Comments

0 comments

Please sign in to leave a comment.