title: Changing background image with jquery
body: <p>I will have a list of images (tiled background type)
  I would like to be able to click on an image and make it the background image for the entire body for display purposes.  so far I have this:</p>
  
  <pre><code>$(document).ready(function(){       
  
      //var image = ???; what should be here?
  
      $('.img1').click(function(){
          $('#body').css('background-image', 'url(images/tiles/tile77.jpg'); //the image url cannot be one single url
          });   
  
      });   
  </code></pre>
  
  <p>my current row of images(just being used to get the script working. The images will be coming from a database later.</p>
  
  <pre><code>&lt;div class="threecol"&gt;&lt;img class="img1" src="images/tiles/tile39.jpg"&gt;&lt;/div&gt;
  &lt;div class="threecol"&gt;&lt;img class="img1" src="images/tiles/tile77.jpg"&gt;&lt;/div&gt;
  &lt;div class="threecol"&gt;&lt;img class="img1" src="images/tiles/tile47.jpg"&gt;&lt;/div&gt;
  &lt;div class="threecol last"&gt;&lt;img class="img1" src="images/tiles/tile33.jpg"&gt;&lt;/div&gt;
  </code></pre>
  
  <p>The script works the way I have it, but I need the background image to be the image that I clicked on, not the static one I have here.  I need it to work each time I click on an image.</p>
  
  <p>I admit it, I am clueless as to how to get it to work time after time and also how to configure the script at .css(background-image, ?????) to be dynamic</p>
  
  <p>Thanks for any advice</p>