Need to add anchor tags to main navmenu

AntonC
Excursionist
56 1 1

Hi all

I was wondering if it's possible to create anchor tags within sections on the homepage and then link to those sections from the main navmenu..

in normal html5 i would just add <a name="navmenu-1"></a> and then link to it using <a href="#navmenu-1">Link to section on homepage</a>
i need to link to different 'image-with-text' and image-with-text-overlay' sections on the homepage.
The customer is not too worried about the SEO hit in using #anchor tags

anyone able to assist?

0 Likes
prinpadure
Explorer
103 29 35

Hi @AntonC 

This might help you: https://community.shopify.com/c/Shopify-Design/Anchor-Link-in-Navigation/m-p/236704/highlight/true#M...

E-mail: rares.holota@gmail.com
Skype: live:2a4135b17a38cd3c
Available for hire
Feel free to contact me
0 Likes
AntonC
Excursionist
56 1 1

Thanks for the reply, it's appreciated.
I got the problem solved by adding 

---------------------------------------------------
{
"type": "text",
"id": "anchor",
"label": "Anchor Tag",
"default": "Enter an anchor tag"
},

-----------------------------------------------------
to the schema within the image-with-text and image-with-text-overlay sections

with a call of

<a name="{{ section.settings.anchor | escape }}"></a>

0 Likes