Hi
I ahve this code which is working on Chrome, Firefox and Safari
But Its not working on IE
Can any one help me
<html>
<script type="text/javascript" language="javascript">
function set_padd(){
var tt = document.getElementById("span_padding").innerHTML;
var txt = new Array();
txt = tt.split("<br>");
var atxt = '';
for(var i = 1; i < txt.length;i++){
if(txt[i].length > 0){
atxt += '<a class="padd_txt" >'+txt[i]+'</a><br />';
}
}
document.getElementById("span_padding").innerHTML = atxt;
}
</script>
<style type="text/css">
.padd_txt{padding:7px;background:#009;color:#FFF;line-height:26px;font-size:14px;}
</style>
<body onload="set_padd();" style="font-family:'Trebuchet MS', Arial, Helvetica, sans-serif; font-size:24px; line-height:1.2em">
<div style="width: 350px;">
<p>
<span id="span_padding" style="background-color: #009; color: #FFF;" class="blocktext">This is what I want to <br />
happen where one<br />
long string is wrapped <br />
and the text has this <br />
highlight color behind <br />it.
</span>
</div>
</body>
</html>