這篇文章主要介紹了CSS如何利用1像素空缺實(shí)現(xiàn)圓角效果,具有一定借鑒價(jià)值,感興趣的朋友可以參考下,希望大家閱讀完這篇文章之后大有收獲,下面讓小編帶著大家一起了解一下。
創(chuàng)新互聯(lián)于2013年開始,先為永和等服務(wù)建站,永和等地企業(yè),進(jìn)行企業(yè)商務(wù)咨詢服務(wù)。為永和企業(yè)網(wǎng)站制作PC+手機(jī)+微官網(wǎng)三網(wǎng)同步一站式服務(wù)解決您的所有建站問題。
代碼如下:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>CSS利用1像素空缺實(shí)現(xiàn)為類圓角效果</title>
<style type="text/css">
body {padding:20px; font-family:arial; text-align:center;}
p, li {font-size: 12px; line-height:18px;}
h4 {margin-bottom:6px;}
.examplesGoHere {text-align:left; margin:0 auto; }
.letsGiveItAFixedWidthOf200Pixels { width:200px; }
ul {list-style:none;margin-left:0;padding-left:0;margin-top:0;}
ul li {margin-bottom:8px; margin-left:0;padding-left:0; }
.notchedListItems a {
display:block;
border: solid #666;
border-width: 0 1px;
text-decoration: none;
outline:none;
color: #000;
background: #e4e4e4;
}
.notchedListItems a b {
display: block;
position:relative;
top: -1px;
left: 0;
border:solid #666;
border-width:1px 0 0;
font-weight:normal;
}
.notchedListItems a b b {
border-width:0 0 1px;
top: 2px;
padding:1px 6px;
}
.notchedListItems a:hover,
.notchedListItems a:hover b {background:#666;color:white;}
.feature {
border:solid #647aae;
border-width:0 1px;
background:#b0c0e6;
}
.feature div {
position:relative;
top: -1px;
left: 0;
border:solid #647aae;
border-width:1px 0 0;
}
.feature div div {
top: 2px;
border-width:0 0 1px;
padding: .3em .3em .1em;
}
</style>
</head>
<body>
<div class="examplesGoHere letsGiveItAFixedWidthOf200Pixels">
<h4>列表示例:</h4>
<ul class="notchedListItems">
<li><a href="/"><b><b>網(wǎng)站首頁(yè)</b></b></a></li>
<li><a href="/jscss/"><b><b>網(wǎng)頁(yè)特效</b></b></a></li>
<li><a href="#"><b><b>軟件下載</b></b></a></li>
</ul>
<h4>DIV區(qū)域:</h4>
<div class="feature">
<div>
<div>
<p>這個(gè)程序雖然不復(fù)雜,但拿來就可以用,簡(jiǎn)單實(shí)用。
而對(duì)于DELPHI愛好者來說,它具有著很方便的報(bào)表模板設(shè)計(jì),
可以打印機(jī)套打,程序使用了Access數(shù)據(jù)庫(kù)和ReportBuilder 7.03控件,
運(yùn)行于Delphi 7.0……</p>
</div>
</div>
</div>
<br/>
<ul class="notchedListItems">
<li><a href="#"><b><b>效果還行吧!</b></b></a></li>
</ul>
</div>
</body>
</html>
感謝你能夠認(rèn)真閱讀完這篇文章,希望小編分享的“CSS如何利用1像素空缺實(shí)現(xiàn)圓角效果”這篇文章對(duì)大家有幫助,同時(shí)也希望大家多多支持創(chuàng)新互聯(lián),關(guān)注創(chuàng)新互聯(lián)行業(yè)資訊頻道,更多相關(guān)知識(shí)等著你來學(xué)習(xí)!
分享標(biāo)題:CSS如何利用1像素空缺實(shí)現(xiàn)圓角效果
當(dāng)前網(wǎng)址:http://www.rwnh.cn/article28/jgjicp.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供品牌網(wǎng)站建設(shè)、網(wǎng)站營(yíng)銷、自適應(yīng)網(wǎng)站、企業(yè)建站、網(wǎng)站設(shè)計(jì)公司、虛擬主機(jī)
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請(qǐng)盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如需處理請(qǐng)聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來源: 創(chuàng)新互聯(lián)