title: Adding data attribute to DOM
body: <pre><code>$('div').data('info', 1);
  
  alert($('div').data('info'));
  //this works    
  
  $('div[data-info="1"]').text('222');
  //but this don't work
  </code></pre>
  
  <p>I'm creating element within jquery. After that, I want to add attribute "data". He's like and is added, but in the DOM, this is not apparent, and I can't get the item, using</p>
  
  <pre><code>$('div[data-example="example"]').html()
  </code></pre>
  
  <p><a href="http://jsfiddle.net/jRFnV/" rel="noreferrer"><strong>jsfiddle</strong></a></p>