title: Find an element by partial ID in jQuery?
body: <p>I have an element on my page, where i only will know part of its <code>id</code>, e.g. <code>_moComments_</code>:</p>
  
  <pre><code>id="MainContent_listSelectedDays_listDayBanks_0_moComments_0"
  </code></pre>
  
  <p>How can i find an element by partial id (e.g. using jQuery)?</p>
  
  <p><strong>For example <a href="http://jsfiddle.net/bjKzu/2/" rel="noreferrer">(jsFiddle)</a></strong>:</p>
  
  <pre><code>&lt;input type="text" id="MainContent_listSelectedDays_listDayBanks_0_moComments_0"&gt;
  </code></pre>
  
  <p>with script</p>
  
  <pre><code>$('[id=_moComments_]').val("Found it");
  </code></pre>
  
  <p><strong>Bonus Reading</strong></p>
  
  <ul>
  <li><a href="http://api.jquery.com/category/selectors/" rel="noreferrer">jQuery selector documentation</a></li>
  <li><a href="https://stackoverflow.com/questions/7873782/jqquery-select-with-partial-name">jQuery select with partial name</a></li>
  <li><a href="https://stackoverflow.com/questions/6488942/how-can-i-make-partial-matches-with-jquery">Making partial matches with jQuery?</a></li>
  </ul>