0

我在一些图片上有几个链接。代码非常简单如下:

<div id="socialnetworkbuttons">
    <a href="http://www.facebook.com/">
        <img src="images/facebook-button.png" alt="Facebook" />
    </a>
    <a href="https://twitter.com/" alt="Twitter">
        <img src="images/twitter-button.png" />
    </a>
</div>

我有一个 reset.css :

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
}

article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
    display: block;
}
body {
    line-height: 1;
}
ol, ul {
    list-style: none;
}
blockquote, q {
    quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
    content: '';
    content: none;
}
table {
    border-collapse: collapse;
    border-spacing: 0;
}

和其他CSS:

#socialnetworkbuttons {
    display:inline-block;
    float:left;
}

结果如下所示:

在此处输入图像描述

如您所见,底部是一个小的紫色省略号人工制品,它是指向 facebook 的链接。我确定我在这里错过了一些非常简单和明显的东西,但是我该如何摆脱呢?!

4

1 回答 1

1

看起来 A 中有多余的空格。试试:

<div id="socialnetworkbuttons"><a
     href="http://www.facebook.com/"><img
        src="images/facebook-button.png" alt="Facebook" /></a><a
     href="https://twitter.com/" alt="Twitter"><img
        src="images/twitter-button.png" /></a>
</div>

我在 Firefox 或 Chrome 上没有省略号。

于 2012-07-02T21:58:25.703 回答