How does the below javascript code work? Can you give me some details?
<pre><code>&lt;button onclick="javascript:this.innerHTML={'true':'Start','false':'Pause'}[G.pause=!!!G.pause];"&gt;Pause&lt;/button&gt;
</code></pre>

<p>If I click the button, it turns to 'start', and it turns to 'pause' when I click again.</p>

<p>I've written another segment like the one above, but it doesn't work as I wish:</p>

<pre><code>&lt;button onclick ="javascript: this.innerHTML{'true':'start','false':'pause'};"&gt;pause&lt;/button&gt; 
</code></pre>

<p>Can anybody tell me why?</p>
