Home > Web Front-end > HTML Tutorial > td和td内图片有间隙,请问如果解决?_html/css_WEB-ITnose

td和td内图片有间隙,请问如果解决?_html/css_WEB-ITnose

WBOY
Release: 2016-06-21 09:47:56
Original
1197 people have browsed it

<table width="210" border="0" cellpadding="0" cellspacing="0" class="pi3" >                                    <tr>                                        <td height="24" style="text-align: left" background="images/bian.jpg">                                            <asp:Repeater ID="RepeaterList" runat="server">                                                <ItemTemplate>                                                    <li><span class="p2fei">&middot;<a href="" title="<%# Eval("name")%>" target="_blank" class="pi3">                                                        <%# Eval("name")%>                                                    </a></span></li>                                                </ItemTemplate>                                            </asp:Repeater>                                        </td>                                    </tr>                                    <tr>                                        <td>                                            <img  src="images/di.jpg"    style="max-width:90%" style="vertical-align: top"/ alt="td和td内图片有间隙,请问如果解决?_html/css_WEB-ITnose" >                                        </td>                                    </tr>                                </table>
Copy after login

我是想实现repeater记录用一个方框包围起来,我在放repeater的td中用了背景,是一个两边有竖道的图,底边这个td我是用img连接的,结果出来的结果是两边的竖道和下面的图就有了间隙。被td隔开了。请问各位高手这个该怎么解决?


回复讨论(解决方案)

用padding试试。。。

padding=0不行啊。还是被隔开了。

image的border设置成0试试

image的border设置成0试试

貌似也不行啊。

cellpadding=0;
cellspacing=0;

把这两个设置了可以不啊

img{ display:block}试试

img{ display:block}试试

隐藏?好像不行啊

align="absbottom"

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template