All Collections
Store
Site settings
Add a social link to the site footer (Javascript)
Add a social link to the site footer (Javascript)

Add a TikTok, Twitch or other link to your site footer

Ed Boaden avatar
Written by Ed Boaden
Updated over a week ago

Site Settings > Design > Advanced > Javascript (or jQuery)

const footerLinkList = document.getElementsByClassName('footer-links-list')[0]

const liTikTok = document.createElement('li');
const aTikTok = document.createElement('a');
const linkTextTikTok = document.createTextNode("TikTok");

liTikTok.appendChild(aTikTok)
aTikTok.appendChild(linkTextTikTok);
aTikTok.href = "https://www.tiktok.com/@xxxx";
aTikTok.target = "_blank"

footerLinkList.insertBefore(liTikTok, footerLinkList.childNodes[9]);

Add the above JS code, replacing the TikTok username on the a.href URL.

Replace linkText with other service name if linking out to something other than TikTok.

Did this answer your question?