jQuery attr title issue
<p>I'm not able to change the title attribute of div dynamically.
Here is my code : </p>

<p><strong>EDIT:</strong></p>

<pre><code>&lt;div id='DivId'&gt;&lt;/div&gt;
</code></pre>

<p>this div is dialog div. 
On click of button 'First' &amp; 'Second', Dialog will open</p>

<pre><code>// On click of button First:
$('#DivId').removeAttr('title');
$('#DivId').attr('title','first');

// On click of button Second:
$('#DivId').removeAttr('title');
$('#DivId').attr('title','second');
</code></pre>

<p>On the first button click, <code>title</code> remains that only, however, on clicking of second button, the title does not change.</p>

<p><strong>EDIT</strong></p>

<p>if I remove <code>$('#DivId').removeAttr('title');</code> then also it is not working.</p>
