代码:
<div id="txt"></div>
<script type="text/javascript">
function removeLabel(){
var txt = document.getElementById("txt").innerHTML;
if(txt==null||txt.length==0){
setInterval(removeLabel(),500);
}else{
document.getElementById("txt").innerHTML=txt.replace(/<.*?>/ig,"").substr(0,100);
}
}
window.addEventListener("load",removeLabel,true);
</script>
IE下为attachEvent