标签:code pen inf href style item content get type
1 $(".iconfont").click(function(){ 2 page=$("input[name=‘count‘]").val(); 3 typeid=$("input[name=‘typeid‘]").val(); 4 $.ajax({url:"index.php?mod=mobile&act=goods&type=ajax", 5 type:‘GET‘, 6 dataType:"json", 7 data:{"page":page,"typeid":typeid}, 8 success:function(data){ 9 if(data.state==1){ 10 tableContent=""; 11 $.each(data.msg,function(i){ 12 var commentInfo = data.msg[i]; 13 var num = i+1; 14 tableContent += ‘<a href="javascript:;" class="aui-flex-links-item">‘; 15 tableContent += ‘<div class="aui-flex-links-img">‘; 16 tableContent += ‘<img src="‘+commentInfo.goods_thumb+‘">‘; 17 tableContent += ‘</div>‘; 18 tableContent += ‘<div class="aui-flex-links-text">‘+commentInfo.goods_name; 19 tableContent += ‘<br>‘; 20 tableContent += ‘<span style="color:#ff5647">‘; 21 tableContent += ‘<i>¥</i>‘+commentInfo.shop_price; 22 tableContent += ‘</span></div>‘; 23 tableContent += ‘</a>‘; 24 }) 25 $(".aui-flex-links").append(tableContent); 26 $("input[name=‘count‘]").val(++page); 27 }else{ 28 $("#show").append(data.msg); 29 $(‘.iconfont‘).css("display","none") 30 } 31 } 32 }); 33 })
标签:code pen inf href style item content get type
原文地址:https://www.cnblogs.com/ssx314/p/10251727.html