title: copy to clipboard - not working in FF,Chrome
body: <p>I am using below mentioned javascript to copy the text to clipboard. Its working in IE, but not working in Firefox and Chrome.</p>
  
  <p>Please advice me,What is wrong?</p>
  
  <pre><code>   function setDataToclipboard() 
  {
  
  var str=document.getElementById("populatedString").value; 
  
  if (window.clipboardData &amp;&amp; clipboardData.setData) {
      clipboardData.setData("Text", str);
      alert("Copied!");
  }
  }
  </code></pre>