Jump to content

Injecting Javascript in body, widget disappearing

Recommended Posts

Site URL: http://www.villageofcapitan.org

Hello!

I am having an issue with a disappearing Javascript widget. I've followed the company's  instructions on  where to  inject the code  and place the widget, etc. It does load and appear when you first visit the homepage, but if you go to another page, then return to the  homepage, the widget is gone or isn't loading.

I tend to avoid Javascript widgets so I am not very knowledgeable about what may be going on.

I placed the <div> code where  I wanted the widget to appear, then injected a Javascript code (that must be before the </body> tag) into the footer area.

 

Does this have something to do with the Ajax being enabled?

 

Any help is appreciated! Thank you!

Edited by melbeedesignstudio
Link to comment
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

16 hours ago, melbeedesignstudio said:

I am having an issue with a disappearing Javascript widget. I've followed the company's  instructions on  where to  inject the code  and place the widget, etc. It does load and appear when you first visit the homepage, but if you go to another page, then return to the  homepage, the widget is gone or isn't loading.

As this 'widget' hasn't been written specifically for Squarespace, you'll need to disable Ajax Page Loading. You'll find the setting within Design > Site Styles.

About: Squarespace Circle Leader since 2017. I value honesty, transparency, diversity and great design ♥.
Work: Squarespace Developer and founder of SF Digital, building the features Squarespace didn't include™. 
Content: Links in my posts may refer to SF Digital products or may be affiliate links.

Catch up on all the release notes and announcements 2023 [for Circle members only]. There's a public version here too!
If I helped, you can thank me by clicking one of the emojis below. If you prefer, you can buy me a coffee.
Improve your online store with our extensions.

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.