112 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 1+ members
  • Located in Australia
  • Has sold $10,000+ on Envato Market
+3 more
ThemeChills says

Hi everyone,

Hoping you can lend me your brains… My theme is found here http://wp.themechills.com/eternity/

Summary of issue
Scroll position does not target the correct section of the page when coming from single post view, or from an external source.

Example repro steps

  1. Click Blog menu item
  2. Click on one of the post items
  3. Once page loads, click back on the RSVP side navigation menu item for example
  4. Scroll position does not land on the RSVP section, it scrolls a few pixels to the Gifts section instead

Would love it if you guys can point me in the right direction?

Leo

47 posts
  • Has sold $10,000+ on Envato Market
  • Has collected 100+ items on Envato Market
  • Located in United Kingdom
  • Sells items exclusively on Envato Market
+1 more
SubatomicThemes says

Hey ThemeChills,

I was wrestling with this problem just the other day. Are you using any jQuery plugins for layouts (e.g. isotope, masonry etc)?

This is what was causing the issue for me, but can’t find a proper solution yet. Floating the masonry items left helped a bit for me.

112 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 1+ members
  • Located in Australia
  • Has sold $10,000+ on Envato Market
+3 more
ThemeChills says

Hey ThemeChills,

I was wrestling with this problem just the other day. Are you using any jQuery plugins for layouts (e.g. isotope, masonry etc)?

This is what was causing the issue for me, but can’t find a proper solution yet. Floating the masonry items left helped a bit for me.

Hi @SubatomicThemes,

The plugins I am using include:

  • FlexSlider
  • Foundation.js
  • jQuery One Page Nav
  • jQuery.ScrollTo

Any ideas?

1 post
  • Has been part of the Envato Community for over 1 year
WildFrog says

Hi ThemeChills,

My guess is that you have a masonry layout or a slider in the same page , which require calculating the height of the section. You can try delaying the scrolling function until the page is loaded.

47 posts
  • Has sold $10,000+ on Envato Market
  • Has collected 100+ items on Envato Market
  • Located in United Kingdom
  • Sells items exclusively on Envato Market
+1 more
SubatomicThemes says

Not really sure but this is my theory;

When the browser looks for the “rsvp” ID, it gets the position before any elements are added (or re-arranged) via javascript. Therefore it will jump to the position is was orignially at. Does that make sense?

Unfortunalety I can’t find a solution yet. A jQuery workaround perhaps? I’ll keep looking into it for now :)

112 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 1+ members
  • Located in Australia
  • Has sold $10,000+ on Envato Market
+3 more
ThemeChills says

Hi ThemeChills, My guess is that you have a masonry layout or a slider in the same page , which require calculating the height of the section. You can try delaying the scrolling function until the page is loaded.

I’m thinking it could be the slider, as I have disabled all JS and once I do, the scroll position is accurate following the same repro steps.

How would your suggestion look in code?

112 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 1+ members
  • Located in Australia
  • Has sold $10,000+ on Envato Market
+3 more
ThemeChills says

Not really sure but this is my theory;

When the browser looks for the “rsvp” ID, it gets the position before any elements are added (or re-arranged) via javascript. Therefore it will jump to the position is was orignially at. Does that make sense?

Unfortunalety I can’t find a solution yet. A jQuery workaround perhaps? I’ll keep looking into it for now :)

Some of the research I did also indicated some of my images not having a set height, though because these are generated by the user and will/can vary, I am unable to put a fixed height/width attribute.

I’ve seen other themes that are doing this effectively, I guess I’m just wondering how this is achieved?

112 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 1+ members
  • Located in Australia
  • Has sold $10,000+ on Envato Market
+3 more
ThemeChills says

Nudging…anyone have a fix for this?

75 posts
  • Has referred 1+ members
  • Has sold $5,000+ on Envato Market
  • Has collected 1+ items on Envato Market
  • Sells items exclusively on Envato Market
Wpsmart says

I checked your theme, its working well, no any issue for me. :)

112 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 1+ members
  • Located in Australia
  • Has sold $10,000+ on Envato Market
+3 more
ThemeChills says

I checked your theme, its working well, no any issue for me. :)

Even when following the above flow?

by
by
by
by
by
by