title: target input by type and name (selector)
body: <p>I need to change some checkbox inputs to hidden inputs for some but not all inputs on a page. </p>
  
  <pre><code>&lt;input type="checkbox" name="ProductCode"value="396P4"&gt; 
  &lt;input type="checkbox" name="ProductCode"value="401P4"&gt; 
  &lt;input type="checkbox" name="ProductCode"value="F460129"&gt;
  </code></pre>
  
  <p>The jquery code below only selects the input by type which causes all check boxes to changed to hidden inputs Is there a way to check for both type of input="checkbox" and name="ProductCode" as the selector so I can specifically target those that I want to change? </p>
  
  <pre><code>$("input[type='checkbox']").each(function(){
  var name = $(this).attr('name'); // grab name of original
  var value = $(this).attr('value'); // grab value of original
  var html = '&lt;input type="hidden" name="'+name+'" value="'+value+'" /&gt;';
  $(this).after(html).remove(); // add new, then remove original input
  });
  </code></pre>
  
  <p> 
   
  </p>