使用try,catch防止页面出错.

jQuery(function(){
	try{
		$(':input').each(function(i){
			var t = $(this).attr('type');
			if(t==='button' || t==='submit'){
				$(this).css({'cursor':'pointer'});
			}
		});
	}catch(e){}

});

Leave a Reply