html的标签云,HTML+CSS入门 用CSS制作伪标签云

本篇教程介绍了HTML+CSS入门 用CSS制作伪标签云,希望阅读本篇文章以后大家有所收获,帮助大家HTML+CSS入门。

<

performance testing stress testing conformance testing acceptane testing smoke testing regression testing white box testing system testing black box testing load testing compatibility testing unit testing

这就是我们要制作的标签云效果。

HTML代码

复制代码

  • performance testing
  • stress testing
  • conformance testing
  • acceptane testing
  • smoke testing

...

复制代码

CSS代码

复制代码

/* 清除ul默认样式 */

.cloud {

display: inline;

list-style-type: none;

width: 400px;

}

.cloud li {

list-style: none;

display: inline;

}

/* 清除ul默认样式 */

.cloud li:nth-of-type(3n + 1) {

font-size: 1.25em;

}

.cloud li:nth-of-type(4n+3) {

font-size: 1.5em;

}

.cloud li:nth-of-type(5n - 3) {

font-size: 1em;

}

复制代码

这个标签云效果并不是随机的,是用:nth-of-type这个CSS属性控制的,所以你刷新页面看到的效果跟这次一样。

不过有什么关系呢,有标签云效果。你可以根据自己的需要对代码更改。

本文由职坐标整理发布,欢迎关注职坐标WEB前端HTML/CSS频道,获取更多HTML/CSS知识!

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值