Jump to content

Add Confetti to a page

Go to solution Solved by kika.tuff,

Recommended Posts

Site URL: https://www.lukaseriksen.com/

So I really want to add a confetti animation to when someone purchases a product on my site. I have scoured the interwebs and have found some code which may let me do this, but I have no idea how i can integrate it into squarespace (https://codemyui.com/falling-confetti/) could anyone help me out with this? I would be super dooper thankful!

Thanks in advance!

Lukas

Link to comment
On 8/9/2020 at 5:22 AM, LukasEriksen said:

Doesn't matter I've figured it out already! I would however now know how i can have the script fade out over a 5 second period. What kind of code should I inject here?

 

Hey Lukas – I'm looking to do the same! Would you mind sharing how you did it? 🙏 Thanks!

Link to comment
  • 6 months later...
  • Solution

Hey @LukasEriksen! I figured out how to turn off the confetti effect after a certain amount of time. I set mine to turn off after 3 seconds - use the SetTimeOut function, with the command confetti.stop

<script src="https://www.wpromotions.eu/confetti.min.js"></script>
<script>confetti.start()</script>
<script>setTimeout(function(){confetti.stop();},3000)</script>

 

Link to comment
  • 7 months later...
On 10/28/2021 at 1:02 AM, SSong said:

Not sure why but the announcement bar appears twice (stacked on top of one another) after I added the confetti code to the order confirmation code block. Can anyone help?

Screen Shot 2021-10-27 at 2.02.43 PM.png

Can you share link to your site? We can check easier

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • 2 weeks later...
  • 1 year later...

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.