100字范文,内容丰富有趣,生活中的好帮手!
100字范文 > 行内元素如何转换成行内块元素使用?

行内元素如何转换成行内块元素使用?

时间:2018-09-17 18:14:17

相关推荐

行内元素如何转换成行内块元素使用?

做成下面的效果该如何来做呢?

代码如下:

<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>行内块元素练习</title><style>.box {margin: 211px auto;text-align: center;color: #333;}.box a {display: inline-block;height: 36px;width: 36px;border: 1px solid #ccc;text-align: center;line-height: 36px;background-color: #f7f7f7;text-decoration: none;color: #333;}.box .prev,.box .next {width: 72px;}input{width: 40px;height: 34px;outline: none;border: 1px solid #ccc;}button{width:72px;height: 36px;line-height: 36px;border: 1px solid #ccc;background-color: #f7f7f7;}.box .current{border: none;background-color: #fff;}</style></head><body><div class="box"><a href="#" class="prev">&lt;&lt;上一页</a><a href="#">1</a><a href="#" class="current">2</a><a href="#">3</a><a href="#">4</a><a href="#">5</a><a href="#">6</a><a href="#">7</a><a href="#">8</a><a href="#" class="next">&gt;&gt;下一页</a>到第<input type="text">页<button>确定</button></div></body></html>

总结:主要用到行内元素与行内块元素的转换问题、和一些基础的问题。

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。