title: JavaScript change div's URL with multiple img's src when using onmouseover img's, using 'this' key, and function
body: <p>I have one div with <code>id='image'</code> and <code>background-image url</code>, and I have 3 images with different <code>src</code>'s- <code>src='/some.jpg'</code> and <code>onmouseover='someFunction(this)'</code></p>
  <p>I want when I put my mouse on one image to change div image to image that I put my mouse on.</p>
  <p>I will leave function empty, I know I need to do <code>document.getElementById ('image')</code> and I tried a lot, with <code>style.background-image</code> and with variable, but obviously I'm doing something wrong</p>
  <p>This is just one of many codes that I tried-</p>
  <pre><code>     &lt;div id=&quot;image&quot;&gt; display here&lt;/div&gt;
      
          &lt;img
            class=&quot;preview&quot;
            src=&quot;/img/tee1.jpg&quot;
            alt=&quot;teaTime&quot;
            onmouseover=&quot;upDate(this)&quot;
            
          /&gt;
  &lt;img
            class=&quot;preview&quot;
            src=&quot;/img/tee2.jpg&quot;
            alt=&quot;teaTime2&quot;
            onmouseover=&quot;upDate(this)&quot;
            
          /&gt;
  &lt;img
            class=&quot;preview&quot;
            src=&quot;/img/tee3.jpg&quot;
            alt=&quot;teaTime3&quot;
            onmouseover=&quot;upDate(this)&quot;
            
          /&gt;
      #image {
        background-image: url(&quot;/img/tee3.jpg&quot;);
        background-color: bisque;
        width: 300px;
        height: 300px;
        border: 5px solid black;
       }
      function upDate(element) {
      
      
      }
  </code></pre>