用了很多方法还是做不出这效果。而且这个小三角我也打不出来。
1 回答
FSYu
TA贡献152条经验 获得超59个赞
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Document</title> <style> * { margin: 0; padding: 0; } .box { width: 100%; clear: both; } .n1 { width: 50%; float: left; } .tu { background: red; height: 300px; width: 50%; float: left; } .txt { background: blue; height: 300px; width: 50%; float: right; position: relative; } .jiao { position: absolute; left: -30px; top: 50%; margin-top: -30px; width: 0; height: 0; border-top: 30px solid transparent; border-right: 30px solid blue; border-bottom: 30px solid transparent; } </style> </head> <body> <div class="box"> <div> <div class="n1"> <div class="tu"></div> <div class="txt"> <div class="jiao"></div> </div> </div> <div class="n1"> <div class="tu"></div> <div class="txt"> <div class="jiao"></div> </div> </div> </div> </div> </body> </html>
要下班了,只打了第一行的。第二行同理,你自己看着弄吧!
- 1 回答
- 0 关注
- 1123 浏览
相关问题推荐
添加回答
举报
0/150
提交
取消