Javascript change link color bug?
<p>My code is:</p>

<pre><code>&lt;a href="#" onclick="javascript:if(document.body.style.backgroundColor!='#000000'){document.body.style.backgroundColor='#000000';}else{alert('test');}"&gt;linkhere&lt;/a&gt;
</code></pre>

<p>If I paste this into jsfiddle (<a href="http://jsfiddle.net/ey7Lv/" rel="nofollow">http://jsfiddle.net/ey7Lv/</a>) and run it does not show the alert on the second click.  But I can see nothing wrong with the code.</p>

<p>What am I doing wrong here?</p>

<p>update with RGB: <a href="http://jsfiddle.net/ey7Lv/16/" rel="nofollow">http://jsfiddle.net/ey7Lv/16/</a>  Still not activating the alert on second click.</p>
