按照老師的的寫,沒有效果
html:
<!doctype html>
<html>
<head>
<meta charset="utf-8>
<link rel="stylesheet" href="cssborder.css" type="text/css">
</head>
<div class="bordertest"></div>
</html>
css:
.bordertest{
width:150px;height:30px;
padding:15px 0;
border-top:30px solid "#fff";
border-bottom:30px solid "#fff";
background-color:"#fff";
background-clip:content-box;
}
2018-07-26
把最后的content-box改成你的名字bordertest,然后就好啦。我的是這樣:
.line-tri{
width: 150px;
height: 30px;
padding: 15px 0;
border-top: 30px solid green;
border-bottom: 30px solid red;
background: orange;
background-clip: line-tri;
}
2016-11-01
Lz你好,你試著改下代碼
首先<div class="bordertest"></div>是要放在<body></body>標(biāo)簽中的;
其實(shí)你要的效果已經(jīng)實(shí)現(xiàn)了,只是你把它們都設(shè)成了#fff, 這是白色. 自然就什么都看不到了.
2016-08-31
嗯,是要實(shí)現(xiàn)三道杠,截錯(cuò)了圖,但是不管加不加引號(hào)都不能實(shí)現(xiàn)三道杠……你在你那里驗(yàn)證過了嗎??
2016-08-30
你是要實(shí)現(xiàn)三道杠???border-top:30px solid "#fff"中#fff不應(yīng)該加引號(hào)……