实例如下:
$('.imglist li').after(function (i) {
var css = "";
if (i % 3 == 2) {
css = "";
}
return css;
}); //图片列表photo.html 隔3行 虚线
var css = "";
if (i % 3 == 2) {
css = "";
}
return css;
}); //图片列表photo.html 隔3行 虚线
});
i 是
图片隔三行加虚线,最后一行去掉虚线,还可以这样
");
}
}
$(".photo_list li:last").css("border-bottom","none");
})
{
height:80px;
}
.dashed{border-bottom:1px dashed #b9c3c7;padding-bottom:10px;margin-bottom:10px}
.clear{clear:both}
.imglist ul li {text-align:center;line-height:25px;float:left}
以上这篇jquery li标签 隔若干行加空白或者加虚线的方法就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持编程之家。