Fixed Image Background causing weird twitch on IE browser

Hi,

I have a div block with the background image set to fixed.

The fixed position works smoothly with the chrome browser, but starts twitches when it comes to IE.

How can i fix this problem?

Thank you,

Can you try adding this to your body code, publishing, and letting us know what happens?

<script>
if(navigator.userAgent.match(/Trident\/7\./)) {
  document.body.addEventListener("mousewheel", function() {
    event.preventDefault();
    var wd = event.wheelDelta;
    var csp = window.pageYOffset;
    window.scrollTo(0, csp - wd);
  });
}
</script> 

Here’s a link regarding adding custom code for anyone who’s interested:

From your Site Settings, go to the Custom Code tab, add your code into the Body Code section, and click Save Changes.

1 Like

Hi @McGuire,

It fixed the problem perfectly!

Thank you so much ;D

1 Like