Jump to content

Extra "}" Creating Problems in Header

Recommended Posts

  • Replies 4
  • Views 268
  • Created
  • Last Reply

Top Posters In This Topic

I suspect you have a syntax error in Settings > Advanced > Code Injection > HEADER.

Look for the following text...

}<style>

...and replace with...

<style>

You need to remove the errant right curly bracket.

Let us know how it goes.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment

Thanks for the advice, but I'm not finding anything like that in code injection > HEADER. I have copied the code from that section below. See anything I should remove?

 

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-201214163-1"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'UA-201214163-1');
</script>

 

I tried removing the bracket that comes just after "(arguments);" but that didn't do the trick. I don't see any others in here. Are there any other coding sections where this issue could be coming up?

Link to comment

The second place to look is Page Settings > Advanced > Page Header Code Injection for the home page. Please see per-page code injection.

That seems more likely now as it appears the issue is only happening on the homepage.

Let us know what you find.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.