Shopify themes, liquid, logos, and UX
Hi.
im wanting to put my phone number and email address in announcement bar, do anyone know how i can do this?
kind regards,
Solved! Go to the solution
This is an accepted solution.
Hello,
You can add links to your site's announcement bar by doing the following:
<p class="announcement-bar__message h5">
{{ block.settings.text | escape }}
{%- if block.settings.link != blank -%}
{% render 'icon-arrow' %}
{%- endif -%}
</p>
6. Remove the '| escape' from the {{ block.settings.text | escape}} line. It should now look like:
<p class="announcement-bar__message h5">
{{ block.settings.text }}
{%- if block.settings.link != blank -%}
{% render 'icon-arrow' %}
{%- endif -%}
</p>
7. Save the changes
8. Back in the theme customizer on your announcement bar's text settings enter the following
Welcome to our store! <a href="tel:1234567890">Call us!</a> <a href="mailto:example@example.com">Email us!</a>
9. The a tags can now be wrapped around any text to create a link. tel: prefix lets the browser know it is a phone number & mailto: let's the browser know it is an email.
Weekly Shopify advice: ShopSavvy newsletter
This is an accepted solution.
Hello,
You can add links to your site's announcement bar by doing the following:
<p class="announcement-bar__message h5">
{{ block.settings.text | escape }}
{%- if block.settings.link != blank -%}
{% render 'icon-arrow' %}
{%- endif -%}
</p>
6. Remove the '| escape' from the {{ block.settings.text | escape}} line. It should now look like:
<p class="announcement-bar__message h5">
{{ block.settings.text }}
{%- if block.settings.link != blank -%}
{% render 'icon-arrow' %}
{%- endif -%}
</p>
7. Save the changes
8. Back in the theme customizer on your announcement bar's text settings enter the following
Welcome to our store! <a href="tel:1234567890">Call us!</a> <a href="mailto:example@example.com">Email us!</a>
9. The a tags can now be wrapped around any text to create a link. tel: prefix lets the browser know it is a phone number & mailto: let's the browser know it is an email.
Weekly Shopify advice: ShopSavvy newsletter
Can I left justify it without it being a global setting for all announcements?
Grettings, can help me w the step 8.
In the "Announcement message" field, type in your phone number and email address, like this:
For phone number: "Call us at: 123-456-7890"
For email address: "Email us at: info@example.com"
Click "Save" to save your changes.
If this fixed your issue, likes and accepting as a solution are highly appreciated.
Build an online presence with our custom built Shopify Theme EcomifyTheme
Ho ho ho
By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024Thanks to everyone who participated in our AMA with 2H Media: Marketing Your Shopify St...
By Jacqui Sep 6, 2024