title: How to disable onclick of a class
body: <p>I would like to know how to disable the onclick event of a certain class. I am aware that you can use the CSS <code>pointer-events: none;</code> however I would like for the hover events to still work, just onclick to be disabled.</p>
  
  <p>Also how do I re-enable them later? For example:</p>
  
  <pre><code>if (document.getElementById('wuzi').backgroundColor == "green" ) {
   //disable onclick
   } else {
   //enable onclick
  }
  </code></pre>
  
  <p>Thank you</p>