title: How to pass parameter in onclick function in javascript
body: <p>Inside javaScript function i code like this...</p>
  
  <pre><code>function myFunction(){
  .....
  
  completeTreeView = completeTreeView + 
     "&lt;li&gt;&lt;input type='checkbox' id=" + name +
     " /&gt;&lt;label for='item-0' onclick='myclicktest(\'' + result.name +
     '\')' &gt;" + Address + "&lt;/label&gt;";
  
  .......
  }
  
  function myclicktest(name){
              alert(name);
  }
  </code></pre>
  
  <p>How to pass and get the result.name</p>