The following code works in a textarea box Firefox but not IE8:
In IE, when you hit enter, there are no carriage returns and the text line does not break.
Thanks in advance for your help
Code:
<script language="javascript">
function repp()
{
var ss = document.getElementById('text').value;
ss = ss.replace(/(\r\n)|(\n)/g,"<br />");
document.getElementById('text').value = ss;
}
</script>
Thanks in advance for your help
Comment