title: onMouseOver not triggering specific function
body: <p>I'm having a very confusing issue and I was wondering if someone could shed some light on it.  </p>
  
  <p>I have a DIV element ...</p>
  
  <pre><code>&lt;div onmouseout="scrollRight();" onmouseover="scrollLeft();" id="rightScrollRegion" class="ScrollRegion"&gt;&lt;/div&gt;
  </code></pre>
  
  <p>And an external script file that has ...</p>
  
  <pre><code>function scrollLeft(){
          document.getElementById('rightScrollRegion').style.background = "#0000ff";
      }
  
      function scrollRight(){
          document.getElementById('rightScrollRegion').style.background = "#ff0000";
      }
  </code></pre>
  
  <p>The problem is that the onmouseover does not seem to call the function scrollLeft(); or scrollRight();  I don't seem to understand where I made an error.</p>
  
  <p>I did some testing to see if it was something in the function...</p>
  
  <p>window.onload = function(){</p>
  
  <pre><code>scrollLeft();
  </code></pre>
  
  <p>}</p>
  
  <p>Works in the external file and changes the DIV's background when the pageloads ... so function works.</p>
  
  <p>I also tried changing what's called in onmouseover ...</p>
  
  <pre><code>&lt;div onmouseover="alert('Hello');" id="rightScrollRegion" class="ScrollRegion"&gt;&lt;/div&gt;
  </code></pre>
  
  <p>prints an alert window just fine.</p>
  
  <p>So I thought maybe I couldn't change the background using onmouseover so I tried ...</p>
  
  <pre><code>&lt;div onmouseover="this.style.background = '#0000ff'" id="rightScrollRegion" class="ScrollRegion"&gt;&lt;/div&gt;
  </code></pre>
  
  <p>And that changes the background as expected.  </p>
  
  <p>But for some reason I can't get my function to trigger on the DIV.  I've search all over the internet and I haven't been unable to find a solution to the issue.  I can't seem to find out what I'm doing wrong.  I've used external functions in other sites but never with an onmouseover so I'm not sure what could be the issue.  </p>
  
  <p>Any help would be greatly appreciated.</p>