title: Edit Style Attribute of every div in a list
body: <p>I'm trying to write a script to help out a colourblind friend of mine.</p>
  
  <p>He's on a page laid out like this:</p>
  
  <pre><code>&lt;div class="message-pane-wrapper candy-has-subject"&gt;
      &lt;ul class="message-pane"&gt;
          &lt;li&gt;&lt;div style="color:#700400"&gt;&lt;/div&gt;&lt;/li&gt;
          &lt;!-- many more li items --&gt;
      &lt;/ul&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>What I'm trying to do is use JavaScript to change all of the style tags so the color is the same.</p>
  
  <p>I've tried looping through like this:</p>
  
  <pre><code>var div = document.getElementById('message-pane-wrapper candy-has-subject');
  var divs = div.getElementsByTagName('div');
  for (var i = 0; i &lt; divs.length; i += 1) {
     divs[i].style = 'color:#00000';
  }
  </code></pre>
  
  <p>But I don't think it's right...</p>