jquery是Yii集成的,利用jquery写的代码$(document).ready(function(){// 操作列表$('.operate').mouseover(function() {$('#operate-'+$(this).attr('key')).show();}).mouseout(function() {$('#operate-'+$(this).attr('key')).hide();});$('.toggle-btn a,.delete-a').live('click',function() {var str = $(this).html();var vid = $('.grid-view').attr('id');if(!confirm('确定要'+str+'吗?')) return false;var th=this;var afterDelete=function(){};$.fn.yiiGridView.update(vid, {type:'POST',url:$(this).attr('href'),success:function(data) {$.fn.yiiGridView.update(vid);afterDelete(th,true,data);},error:function(XHR) {return afterDelete(th,false,XHR);}});return false;});第九行说我“$”未定义。。不明白原因
添加回答
举报
0/150
提交
取消