Accessing custom fields in theme

Thank you @Ealfardan

I can’t say i knew exactly what i was doing :smiley:

But now i managed to get it working this way:

{% if custom_fields["Show VAT Number"] and custom_fields["Show VAT Number"] == 'Yes' %}
<div style="font-weight: bold; padding-top: 10px">VAT # : {{ business.custom_fields["VAT Number"] }}</div>
{% endif %}

{% if custom_fields["Show HST Number"] and custom_fields["Show HST Number"] == 'Yes' %}
<div style="font-weight: bold; padding-top: 10px">HST # : {{ business.custom_fields["HST Reg. No"] }}</div>
{% endif %}
1 Like