Jump to content

Scroll to products on category change

Recommended Posts

  • 2 weeks later...
1 hour ago, bethol said:

@creedon Thank you! Unfortunatly it did not work 😞 

The code work perfectly, but there is a syntax error on your site, find position of the snippet in red box and remove the read-underline text

image.png.eb1888f2554262f7f2be39239073376e.png

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date format)
💫 Animated Buttons (Referral URL)
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment
7 minutes ago, bethol said:

@bangank36 I removed the whole "read more" snippet with the underlined text, but it didnt change anything.

@creedon I took a look but the condition never met

twcsl.storePage.hasCategory

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date format)
💫 Animated Buttons (Referral URL)
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment

@bethol @bangank36

I have updated my code post. The second line of the first instruction has been updated. There was a bug in my code. Hopefully that has been fixed now!

Let me 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
40 minutes ago, bethol said:

@creedon @bangank36 It still refreshes to the top of the page. Maybe i´m doing something wrong?

 

 

Hang on while Creedon updates his awesome plugin

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date format)
💫 Animated Buttons (Referral URL)
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment

I've updated my twcsl code again.

However I've discovered an issue that I'm not having on my test site. I think it has to do with the fact that you have five instances of the jQuery library being loaded. Generally only one is needed unless you have a specific need for multiple versions.

The code is not running in the order I normally expect. The scroll to top of store category product grid code is running before twcsl which is not good.

I'd be happy to go in and try to clean up that situation and it would give me an opportunity to test my code further.

You'd need to invite me as a contributor with Administrator permissions. If you're up for this let me know and I'll send my email out of band.

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

I've gone in and commented out extra jQuery libraries. I also fixed a few syntax errors. An odd non printing character was causing an issue. Also a jQuery document ready was nested inside another.

My code appears to be working well. The scroll effect is happening as I would expect.

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.