2013-02-22 34 views
-1
图像阴影

有谁知道如何像这样创建CSS:创建CSS

enter image description here

请帮我的家伙,居然创建按钮的阴影。

好吧,我已经试过这一点,并难以创造阴影:

CSS代码

a{ 
    display: inline-block; 
    width:9px; 
    height:9px; 
    border-radius:50px; 
    font-size:20px; 
    color:#fff; 
    line-height:100px; 
    text-align:center; 
    text-decoration:none; 
    background-color: #1f1f1f !important; 
    margin: 2px 2px 2px 2px !important; 
    border: 1px #bebebd inset; 
} 

a.active { 
    display: inline-block; 
    width:10px; 
    height:10px; 
    border-radius:50px; 
    font-size:20px; 
    color:#fff; 
    line-height:100px; 
    text-align:center; 
    text-decoration:none; 
    background-color: #2880d7 !important; 
    margin: 2px 2px 2px 2px !important; 
    border: 0px; 
} 

HTML代码

<a href="#"></a> 
<a href="#" class="active"></a> 

请帮我的家伙,居然创建按钮的阴影。

预先感谢

+0

是的,这是我的功课,我尝试了这些:
Manellen 2013-02-22 07:15:28

+0

a{ display: inline-block; width:9px; height:9px; border-radius:50px; font-size:20px; color:#fff; line-height:100px; text-align:center; text-decoration:none; background-color: #1f1f1f !important; margin: 2px 2px 2px 2px !important; border: 1px #bebebd inset; } Manellen 2013-02-22 07:19:20

+0

a.active{ display: inline-block; width:10px; height:10px; border-radius:50px; font-size:20px; color:#fff; line-height:100px; text-align:center; text-decoration:none; background-color: #2880d7 !important; margin: 2px 2px 2px 2px !important; border: 0px; } Manellen 2013-02-22 07:19:46

回答

0
a{ 
    display: inline-block; 
    width:9px; 
    height:9px; 
    border-radius:50px; 
    font-size:20px; 
    color:#fff; 
    line-height:100px; 
    text-align:center; 
    text-decoration:none; 
    background-color: #1f1f1f !important; 
    margin: 2px 2px 2px 2px !important; 
    border: 1px #bebebd inset; 
    box-shadow: 2px 2px 5px #888888; 
} 

与你的CSS a{}

取代这个如果是不够的,你看这link

+0

嗨ANK,谢谢你的回应,当我们看到那些图像时,描述阴影是内在的阴影,那么怎么样? – Manellen 2013-02-22 09:40:09

+0

在CSS .a类中使用box-shadow标记。通过这个标签,我们必须设置水平阴影的位置,垂直阴影的位置,阴影的大小和阴影的颜色... – 2013-02-22 09:57:12

+1

谢谢ANK,我用你的建议来使用盒子阴影。 – Manellen 2013-02-25 04:47:55