javascript - how to prevent page from scrolling when loading new content to page -


I have a page website with anchor for anchor, content is being loaded dynamically when I see Dint (when someone For example, click on anchor or scroll for position on the site) For example:

  • Anchor 1 & gt; Div1
  • Anchor 2 & gt; Div2
  • Anchor 3 & gt; Div3
  • Anchor 4 & gt; Div4

    etc

    But when you load the page and click on the 3 anchors, it will take you there, but then div2 wchich loaded on the jump has gone.

    Is there any way to prevent this and bind vieport to show DivX content?

    Thanks for any help!

    Turn it on onclick event.

      $ ('html, body'). ({scrollTop: '100 (PXValue)'}, 1000, linear ');    

Comments

Popular posts from this blog

Java - Error: no suitable method found for add(int, java.lang.String) -

java - JPA TypedQuery: Parameter value element did not match expected type -

c++ - static template member variable has internal linkage but is not defined -