Solved

How can I add a tracking script to every page quickly?

JustG
New Member
4 0 0

Hey guys,

Sorry for the newbie question but I've just added a tracking app and it's asking me to put a specifc code on every page. Is there a way I can paste it into .liquid to do it quicky? Thanks in advance for the advice!

Accepted Solution (1)
suyash1
Shopify Partner
9308 1155 1495

This is an accepted solution.

@JustG - any screenshot of the  code?

 

most probably it is javascript and put it before </head> in theme.liquid file

To build shopify pages use pagefly
You are welcome to contact me - suyash.patankar@gmail.com , My timezone is GMT+5:30.
Paranormal story video using AI

View solution in original post

Replies 9 (9)

suyash1
Shopify Partner
9308 1155 1495

@JustG 

 

if it needs to be put on every page then it needs to be put it before </head> or </body> in theme.liquid, what does the app say?

To build shopify pages use pagefly
You are welcome to contact me - suyash.patankar@gmail.com , My timezone is GMT+5:30.
Paranormal story video using AI
JustG
New Member
4 0 0

Thanks for getting back to me. It says:

"Place the following tracking code on all pages of your site. The code is asynchronous and will not block your page from loading."

I'm not quite sure what that means.

Mirokuwu
Shopify Partner
16 2 1

theme.liquid display on every page of your site, so just put it in theme.liquid

suyash1
Shopify Partner
9308 1155 1495

This is an accepted solution.

@JustG - any screenshot of the  code?

 

most probably it is javascript and put it before </head> in theme.liquid file

To build shopify pages use pagefly
You are welcome to contact me - suyash.patankar@gmail.com , My timezone is GMT+5:30.
Paranormal story video using AI
JustG
New Member
4 0 0
<script type='text/javascript'>
window.__lo_site_id = 264508;
 
(function() {
var wa = document.createElement('script'); wa.type = 'text/javascript'; wa.async = true;
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(wa, s);
  })();
</script>
suyash1
Shopify Partner
9308 1155 1495
yes put it in theme.liquid file before or if you find it difficult
then please add me to staff, you can contact me on given details below.
To build shopify pages use pagefly
You are welcome to contact me - suyash.patankar@gmail.com , My timezone is GMT+5:30.
Paranormal story video using AI
JustG
New Member
4 0 0

Thank you! I think that's in okay now. 

Much appreciated 🙂

suyash1
Shopify Partner
9308 1155 1495
sure, if you need anything, let me know. I will help to the best of my
knowledge.
To build shopify pages use pagefly
You are welcome to contact me - suyash.patankar@gmail.com , My timezone is GMT+5:30.
Paranormal story video using AI
zayan
Visitor
1 0 0

Thanks for your suggestions, I also have a tool based tracking site. For more info, you can click here.