Uncaught TypeError: $(...).carousel is not a function(anonymous function) @ index.php?m=content&c=index&a=lists&catid=22:600
这个错我真看不懂,压根没定义就去调用
fmrw.js:96 Uncaught ReferenceError: fmrwClass is not defined(anonymous function) @ fmrw.js:96b.event.dispatch @ jquery-1.9.1.min.js:2v.handle @ jquery-1.9.1.min.js:2
我跟你讲这错误特傻逼
来看代码
fmrw.js:96行:
if(fmrwClass!=undefined){
$("#page").attr("class",fmrwClass)
}
undefined检测要用typeof啊要不然就报错啊喂,直接判断!=怎么可能不报错嘛
if(typeof(fmrwClass)!="undefined"){
$("#page").attr("class",fmrwClass)
}
这才是科学的做法好嘛! |