Jump to content

Squarespace editor is blinking

Recommended Posts

Hello

when I add the following code to a page's Tag in Squarespace the editor starts blinking:

<script> window.location.href = "https://google.com" </script>

This is just an example. In the end I want to link to my discord Oauth2 login page. See the video below to get an idea of what happens:

Video

Link to comment

Looks like there's something not right with that code. What is the real code you want to install and what is it meant to do?

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment
51 minutes ago, hohe34 said:

<script> window.location.href = "https://google.com" </script>

This code appears to want to reload the window, so I wouldn't use this type of script as it is directly causing the reloading.

Without knowing the code you actually want to use, or it's purpose, sorry but I can't help.

Edited by Ziggy

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment
1 hour ago, hohe34 said:

Why does this code reload the window? It just redirects to google.com

Yes, it does but you don't really want your website to load and redirect to google every time you load it, and that is causing the flashing as it loops through trying to load Google and then goes back to your website.

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment

So I bascically used the same approach to redirect to a discord oauth2 web page. On that page people have to sign in with their discord credentials. They then get redirected back to the page with them being signed in. The redirect should happen everytime they go to that page

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.