Liquid, JavaScript, themes, sales channels
Hello,
I'm using the Dawn theme - the new Shopify free theme - and I want to update the payment icons in my footer.
Tried to follow this tutorial, by Shopify (that works for Debut, as an example), but it's not working.
I suspect that the code that needs to be edited is the following one, in footer.liquid
{%- if section.settings.payment_enable -%}
<div class="footer__payment">
<span class="visually-hidden">{{ 'sections.footer.payment' | t }}</span>
<ul class="list list-payment" role="list">
{%- for type in shop.enabled_payment_types -%}
<li class="list-payment__item">
{{ type | payment_type_svg_tag: class: 'icon icon--full-color' }}
</li>
{%- endfor -%}
</ul>
</div>
{%- endif -%}
Does anyone knows how I can fix this?
Thank you
Solved! Go to the solution
This is an accepted solution.
Does anyone knows how I can do this, in Dawn theme?
{% for type in shop.enabled_payment_types %}
Replace it with:
{% assign enabled_payment_types = 'visa,master,american_express,paypal' | remove: ' ' | split: ',' %}
{% for type in enabled_payment_types %}
Thank you
This is an accepted solution.
Don't know if you figured this out but just replace the code in your first post with this (update your preferred payment methods if needed):
{%- if section.settings.payment_enable -%}
<div class="footer__payment">
<span class="visually-hidden">{{ 'sections.footer.payment' | t }}</span>
<ul class="list list-payment" role="list">
{% assign enabled_payment_types = 'visa,master,american_express,paypal,venmo' | remove: ' ' | split: ',' %}
{% for type in enabled_payment_types %}
{{ type | payment_type_svg_tag: class: 'icon icon--full-color' }}
</li>
{%- endfor -%}
</ul>
</div>
{%- endif -%}
For me it's lines 294-305 in footer.liquid
This is an accepted solution.
Does anyone knows how I can do this, in Dawn theme?
{% for type in shop.enabled_payment_types %}
Replace it with:
{% assign enabled_payment_types = 'visa,master,american_express,paypal' | remove: ' ' | split: ',' %}
{% for type in enabled_payment_types %}
Thank you
No one?
This is an accepted solution.
Don't know if you figured this out but just replace the code in your first post with this (update your preferred payment methods if needed):
{%- if section.settings.payment_enable -%}
<div class="footer__payment">
<span class="visually-hidden">{{ 'sections.footer.payment' | t }}</span>
<ul class="list list-payment" role="list">
{% assign enabled_payment_types = 'visa,master,american_express,paypal,venmo' | remove: ' ' | split: ',' %}
{% for type in enabled_payment_types %}
{{ type | payment_type_svg_tag: class: 'icon icon--full-color' }}
</li>
{%- endfor -%}
</ul>
</div>
{%- endif -%}
For me it's lines 294-305 in footer.liquid
Hello @miin ,
I found out later, what I was doing wrong.
I will accept your solution.
Thank you 🙂
Hey, how can I display these payment icons under the Add to Cart / Buy now Buttons?
Also wanting to know this if anyone can help
Works perfectly..!
Portrait of Stephen positioned next to an image of planet Earth, with the Stephen's World ...
By JasonH Mar 18, 2024Digital marketers and app developers have tracked activity in apps and websites for yea...
By Ollie Mar 13, 2024February was an exciting month with Shopify Editions, informative webinars, and more! F...
By JasonH Mar 7, 2024