title: How do I display randomly-chosen text with an associated image?
body: <p>I'm a beginner web designer and I need to know how can I link one thing to another. The thing is that I'm making different quotes change every time the site refreshes. 
  And I need to do the same thing with images that are located in a different div tag. The reason I need to link them is because the image needs to coordinate with the quote. 
  For example: quote 0 with image 0.</p>
  
  <p>Here is the javascript code:</p>
  
  <pre><code>var quotes=new Array();
  quotes[0] = "text1";
  quotes[1] = "Text2";
  quotes[2] = "text3";
  quotes[3] = "text4";
  
  var q = quotes.length;
  var whichquote=Math.round(Math.random()*(q-1));
  function showquote(){document.write(quotes[whichquote]);}
  showquote();
  </code></pre>
  
  <p>And this is the code that is located the javascript text:</p>
  
  <pre><code>&lt;script language="javascript" type="text/javascript" src="quotes.js"&gt;&lt;/script&gt;
  </code></pre>