title: How to select "a" tag has specific file type in href using jQuery?
body: <p>I am targeting links which contain various file types in jQuery using:</p>
  
  <pre><code>jQuery('a[href$=".pdf"], a[href$=".doc"], a[href$=".docx"], a[href$=".ppt"], a[href$=".pptx"], a[href$=".xls"], a[href$=".slxs"], a[href$=".epub"], a[href$=".odp"], a[href$=".ods"], a[href$=".txt"], a[href$=".rtf"]').before('&lt;span class="glyphicon glyphicon-file"&gt;&lt;/span&gt; ');
  </code></pre>
  
  <p>Firstly, is there a way of reducing the repetition? e.g.</p>
  
  <pre><code>jQuery('a[href$=".pdf|.doc|.docx"])
  </code></pre>
  
  <p>And secondly, is there a way to target different cases for the file extensions e.g. <code>Pdf</code>, <code>PDF</code> and <code>pdf</code>?</p>