In my rails app, I am saving a question as html. For example,
"<p><pre dir=\"ltr\" style=\"background-color: #ede7db; color:
#000000; margin: 0px; padding: 6px; border: 1px inset; width: 640px; height: 194px; text-align: left; overflow: auto; background-position: initial initial; background-repeat: initial initial;\" class=\"alt2\">void myFunc (int x) <br />{ <br /> if (x &gt; 0)<br /> myFunc(--x); <br /> printf(\"%d, \", x); <br />} <br />int main() <br />{ <br /> myFunc(5); <br /> return 0; <br />}</pre></p>"
I need to replace all the width attributes with width:auto;
Help me to do the same. Thanks :)-