title: How to set the text node value using jQuery
body: <p>I have a HTML structure like this:</p>
  
  <pre><code>&lt;div class="votes"&gt;
      &lt;b&gt;5&lt;/b&gt; Votes
      &lt;a id="vote-' + element_id +'" href="#" class="vote-btn"&gt;&lt;/a&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I have manage to get the text after 5 i.e. votes using:</p>
  
  <pre><code>var voteTextNode = $(this).parent('div').contents().filter(function() {
                      return this.nodeType == 3;  
                  });
  var voteText = voteTextNode.text();
  </code></pre>
  
  <p>now i want to change this text to vote which is respective number of votes . I have tried this:</p>
  
  <pre><code>voteNewText = ( newCount == '1' ) ? 'Vote' : 'Votes';
  voteTextNode.text(voteNewText);
  </code></pre>
  
  <p>but it does not work for me. I have also tried the code from this link:
  <a href="https://stackoverflow.com/questions/4046482/how-can-i-get-manipulate-and-replace-a-text-node-using-jquery">How can I get, manipulate and replace a text node using jQuery?</a>
  but it also wont work for me tell me where i am doing wrong</p>