Replacing Type attribute text of input outerHTML
<p>As <code>input</code> type change using <code>setAttribute</code> is not supported in IE browsers because of security concerns I am following the below way  </p>

<pre><code> div.innerHTML = ele.outerHTML.replace('type=text' , 'type=password');
</code></pre>

<p>But this is not working if <code>type="text"</code> or <code>type='text'</code> because it was not replaced.. Is there any regex to match the same in generic way and replace it?</p>
