How to insert an anchor link in a 2.0 template?

How to insert an anchor link in a 2.0 template?

aline808
Excursionist
21 0 8

How do I add an anchor link in shopify 2.0 template? I have a template setup for FAQ and have no idea how to link to a section on this page. In version 1.0 I could edit the HTML and add an ID for the area I want to link to. But now that

Replies 11 (11)

Akibhusen
Shopify Partner
715 121 148

Could you please share your code snap or store URL?

aline808
Excursionist
21 0 8

https://www.alwaysaline.com/pages/faq

 

I would like the section Sizing and Garment Care have an anchor link applied so I can direct customers to that section with a URL for our customers.

Akibhusen
Shopify Partner
715 121 148

Ohak. so, do you want to add a link to the main title of each FAQ? correct me if I am wrong.

 

If I am correct could you please share the screenshot of the content you have added to customize screen?

aline808
Excursionist
21 0 8

I only to link to a few sections on the FAQ page. I would usually add an ID to the section and then use that ID for a URL link. For instance the ID would be ORDER and the URL would like this: https://www.alwaysaline.com/#order

Akibhusen
Shopify Partner
715 121 148

Had you tried like the attached screenshot to add a link in the FAQ title?

 

Akibhusen_0-1684865561505.png

 

aline808
Excursionist
21 0 8

this code does not work. 

Akibhusen
Shopify Partner
715 121 148

Okay, I got the issue. Do you have an idea related to liquid coding??

 

If you don't have then I can help you to solve this issue. There are required some changes in your faq template.

aline808
Excursionist
21 0 8

I know enough to get into the Shopify backend page.faq.json template section to edit the code.

 

Akibhusen
Shopify Partner
715 121 148

Open your Faq template liquid file not JSON. you can't find the actual coding in JSON file. 

 

In that liquid template find the code of the fetching header which is written in '{{ }}'.

and in that, if you find like ' | escape' then remove it. and save the file.

 

and after that try to add link from customize screen

 

made4Uo
Shopify Partner
3873 718 1220

Hi @aline808 

What section are you using for the FAQ?

If this fixed your issue Likes and Accept as Solution is highly appreciated. Coffee tips fuels my dedication.
Get EXPERIENCED Shopify developers at affordable rates—visit Made4Uo.com for quick quote!
Do not lost your Shopify store! Get FREE trial with ✔️ Rewind Backup: Automatic, reliable, stress-free
aline808
Excursionist
21 0 8

I don't understand the question...I have a template set up for my FAQ page and I just want to add an anchor link to certain sections. HTML made that easy in SHopify 1.0. 2.0 has me confused. I am not a coder.