CSS拾遺之箭頭,目錄,圖標(biāo)的實(shí)現(xiàn)代碼
發(fā)布時間:2019-11-14 14:33:32 作者:佚名
我要評論

這篇文章主要介紹了CSS拾遺之箭頭,目錄,圖標(biāo)的實(shí)現(xiàn)代碼,代碼簡單易懂,非常不錯,具有一定的參考借鑒價(jià)值,需要的朋友可以參考下
1. CSS拾遺之圖標(biāo)
圖標(biāo)有三種制作方法:
- 圖片
- css(小箭頭用CSS搞定)
- 自己畫font(fontawsome插件)
fontawsome插件下載之后,解壓,新版的與老版不一樣。
2. html文件的目錄結(jié)構(gòu)
xxx project - app - s1.html - s2.html - css - commons.css - script - commons.js - plugin - fontawsome - bootstrap - ...
3. CSS拾遺之a(chǎn)包含標(biāo)簽
image默認(rèn)是有個邊框的,在chrom中沒事,但是在IE Browser里面就會把邊框顯示出來,所以要將image標(biāo)簽的邊框設(shè)為0.
<hedad> <style> img{ border: 0; } /* IE瀏覽器會產(chǎn)生邊框,所以要將邊框設(shè)為0 */ </style> </head> <body> <a href="wwww.baidu.com">lanxing</a> <a href="www.baidu.com"> <img sytle="height:300px;width:400px" src="wallpaper1.jpg" alt="lanxing"> <a> <body>
4. CSS拾遺之箭頭畫法
<style> .up { border-top: 30px solid green; border-right: 30px solid transparent; border-bottom: 30px solid transparent; border-left: 30px solid transparent; display: inline-block; } .down { border-top: 30px solid transparent; border-right: 30px solid transparent; border-bottom: 30px solid red; border-left: 30px solid transparent; display: inline-block; } .c1 { border: 30px solid transparent; border-top: 30px solid green; display: inline-block; margin-top: 40px; } .c1:hover { border: 30px solid transparent; border-bottom: 30px solid green; margin-top: 10px; } </style> </head> <body> <div class="up"></div> <div class="down"></div> <div style="height: 100px; background-color: red;"> <div class="c1"></div> </div> </body>
總結(jié)
以上所述是小編給大家介紹的CSS拾遺之箭頭,目錄,圖標(biāo)的實(shí)現(xiàn)代碼,希望對大家有所幫助,如果大家有任何疑問請給我留言,小編會及時回復(fù)大家的。在此也非常感謝大家對腳本之家網(wǎng)站的支持!
如果你覺得本文對你有幫助,歡迎轉(zhuǎn)載,煩請注明出處,謝謝!
相關(guān)文章
- 這篇文章主要介紹了css記錄文本圖標(biāo)對齊的幾種解決方案,文中通過示例代碼介紹的非常詳細(xì),對大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來一起2020-03-23
CSS3鼠標(biāo)滑過圖片效果 用Font Awesome庫實(shí)現(xiàn)懸停圖標(biāo)
今天給大家?guī)硪粋€比較傳統(tǒng)但卻非常實(shí)用的CSS3應(yīng)用,它的功能是可以快速生成一個帶鼠標(biāo)滑過特效的圖片,需要的朋友前來下載使用2019-10-23CSS運(yùn)用阿里巴巴矢量庫快速在對應(yīng)位置加上好看的圖標(biāo)效果(實(shí)例代碼)
這篇文章主要介紹了CSS運(yùn)用阿里巴巴矢量庫快速在對應(yīng)位置加上好看的圖標(biāo)效果,本文通過實(shí)例代碼給大家介紹的非常詳細(xì),對大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋2020-04-14