title: Matching partial Attribute values with selector
body: <p>Trying to get matches of attributes with wildcards to find out how many elements of a type are on the page</p>
  
  <p>I think I should be able to use queryselectorAll on a partial attribute value as shown below, but no elements found :(</p>
  
  <pre><code>&lt;div class="ag-right-align-cell" data-test="unitPrice&amp;amp;^%^&amp;amp;category=FRED&amp;amp;^%^&amp;amp;displayName=FREDS INFO;field=unitPrice&amp;amp;^%^&amp;amp;^%^&amp;amp;"&gt;$999.99&lt;/div&gt;
  
  &lt;div class="ag-right-align-cell" data-test="unitPrice&amp;amp;^%^&amp;amp;category=GEORGE&amp;amp;^%^&amp;amp;displayName=GEORGES INFO;field=unitPrice&amp;amp;^%^&amp;amp;^%^&amp;amp;"&gt;$999.99&lt;/div&gt;
  
  </code></pre>
  
  <pre class="lang-js prettyprint-override"><code>var el=document.querySelectorAll('[data-test|=unitprice]');
  console.log(el.length);  // = 0
  </code></pre>
  
  <p>el.length shows 0 elements found.</p>
  
  <p>What is the correct javascript for a match for selecting datatest=unitprice* ?</p>