Google Remarketing Code - Non-Sequential Javascript error

Avatar

Avatar
Validate 1
Level 1
roberts58283265
Level 1

Likes

0 likes

Total Posts

2 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
roberts58283265
Level 1

Likes

0 likes

Total Posts

2 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile
roberts58283265
Level 1

16-05-2017

Hello,

Has anyone had issues with trying to add google remarketing codes as non-sequential js?  I keep getting the error Unexpected token < (line: 1; col:1)

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Validate 1000
Community Manager
jantzen_belliston-Adobe
Community Manager

Likes

339 likes

Total Posts

2,331 posts

Correct reply

819 solutions
Top badges earned
Validate 1000
Springboard
Validate 500
Validate 250
Validate 100
View profile

Avatar
Validate 1000
Community Manager
jantzen_belliston-Adobe
Community Manager

Likes

339 likes

Total Posts

2,331 posts

Correct reply

819 solutions
Top badges earned
Validate 1000
Springboard
Validate 500
Validate 250
Validate 100
View profile
jantzen_belliston-Adobe
Community Manager

16-05-2017

Robert,

There is a great article by Jennifer Kunz that goes over converting various marketing pixels from HTML to JS. Have a look at the link below:

https://www.digitaldatatactics.com/index.php/2016/07/06/dtm-third-party/

Thanks,
Jantzen

Answers (2)

Answers (2)

Avatar

Avatar
Validate 1
Level 1
roberts58283265
Level 1

Likes

0 likes

Total Posts

2 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
roberts58283265
Level 1

Likes

0 likes

Total Posts

2 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile
roberts58283265
Level 1

16-05-2017

I pulled the code directly from Adwords.  How do I convert to only .js?

Avatar

Avatar
Validate 10
Level 5
andrew_r-GrfLbX
Level 5

Likes

82 likes

Total Posts

133 posts

Correct reply

36 solutions
Top badges earned
Validate 10
Validate 1
Boost 50
Boost 5
Boost 3
View profile

Avatar
Validate 10
Level 5
andrew_r-GrfLbX
Level 5

Likes

82 likes

Total Posts

133 posts

Correct reply

36 solutions
Top badges earned
Validate 10
Validate 1
Boost 50
Boost 5
Boost 3
View profile
andrew_r-GrfLbX
Level 5

16-05-2017

You have HTML in your tag and it can only contain pure JS, you need to remove all HTML before you can use your tag, otherwise you can change the type to an HTML tag however it's better for performance if you use pure JS.