title: Moving images with MouseWheel
body: <p>I am trying to move an image from side to side using the mousewheel. The image by default is set to absolute position and left=100px. It is not allowing for the scroll to move the image with the parseInt but if I take that out it moves immediately to left=0px. I want to be able to move it a few pixels for each wheel click.</p>
  
  <pre><code> window.onload = function() {
          if (document.body.addEventListener) {
                  document.body.addEventListener("mousewheel", MouseWheelHandler, false);
                  document.body.addEventListener("DOMMouseScroll", MouseWheelHandler, false);
          }
          else document.body.attachEvent("onmousewheel", MouseWheelHandler);
  
          function MouseWheelHandler(e){
              // cross-browser wheel delta
          var e = window.event || e; // old IE support
          var delta = Math.max(-1, Math.min(1, (e.wheelDelta || -e.detail)));
  
          img1.style.left = Math.max(0, Math.min(1100, parseInt(img1.style.left) + (delta))) + "px";
  
          return false;
          }
      };
  </code></pre>