js的自动转换URL函数autoUrl加上个异常处理

This commit is contained in:
yuanke 2016-11-23 13:29:02 +08:00
parent 40c7afbc38
commit 9720f84fce
1 changed files with 15 additions and 2 deletions

View File

@ -1706,8 +1706,15 @@ function autoUrl(id){
}
return reStr ;
});
try{
$(this).html(html);
}
catch (e)
{
console.log(e.name + ": " + e.message);
}
}
});
}
else{
@ -1725,8 +1732,14 @@ function autoUrl(id){
}
return reStr ;
});
try{
$("#"+id).html(html);
}
catch (e)
{
console.log(e.name + ": " + e.message);
}
}
if(!(!!window.ActiveXObject || "ActiveXObject" in window)){
autoMedia(id);
}