How Can i rename the h1 and h2 supply theme?

ADHP
Tourist
9 0 2

Hi good day everyone how can i rename this collection and featured product h1? i try to rename this on 
<h1 class="section-header--title">{{ collection.title }}</h1>
collection list page but the other collection will do the same. 


0 Likes
gina-gregory
Shopify Expert
710 48 175

You would need to change the title of the collection in the admin. If you just want an alternate title for this one collection, you can store that in a metafield, and use that instead.

<h1 class="section-header--title">
{% if collection.metafields.global.title != blank %}
  {{ collection.metafields.global.title }}
{% else %}
  {{ collection.title }}
{% endif %}
</h1>

In this example, the metafield namespace is "global" and the key is "title".

https://shopify.dev/docs/themes/liquid/reference/objects/metafield 

0 Likes