How do I specify a custom image for my referral program's Twitter share?

Modified on Wed, 28 Jun, 2023 at 5:48 AM

The instructions provided below are intended for use only if you feel comfortable editing your store's theme. If you don't feel comfortable making these types of changes, email us at help@shopcircle.co and we can make the changes for you.

First, you'll need to locate where your social meta tags are first. This is usually a snippet that's included in theme.liquid, and the file is typically something like snippets/meta-tags.liquid or snippets/social-meta.liquid, etc. Once you find where your social meta tags are, typically there are a lot of "if" statements determining when to use which meta tags. You'll need to either add to that if statement, or add a new one like this:

{% if template == blank and canonical_url contains 'a/refer-a-friend/redeem' %}

<!-- include conjured referral code for twitter sharing -->

<meta name="twitter:card" content="summary_large_image">

<meta name="twitter:site" content="@YOUR_TWITTER_HANDLE">

<meta name="twitter:creator" content="@YOUR_TWITTER_HANDLE">

<meta name="twitter:title" content="YOUR TITLE">

<meta name="twitter:description" content="YOUR DESCRIPTION">

<meta name="twitter:image" content="TWITTER_IMAGE_URL">

{% endif %}

Make sure you update all the uppercase variables above with your personal content, and that the TWITTER_IMAGE_URL is an image with dimensions 1024px by 512px.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article