Javascript 判断是否存在函数
<div id="cnblogs_post_body"><div class="cnblogs_Highlighter">window.onload=function(){try{if(test&&typeof(test)=="function"){test();}else{alert("不存在的函数");}}catch(e){}}function test(){ alert("函数执行&hellip;&hellip;"); }
页:
[1]