html - Cell padding affected by contained ASP NET image -
i have asp net image contained within html table cell, reason there seems padding @ bottom of cell.
i have tried number of things, no luck:
- removing css padding.
- removing right hand "logged in" cell check isn't influencing other cell.
adjusting size of source image. padding stays 3px high.
<td style="width:200px; vertical-align:top;"> <table class="customtable" style="width:100%; table-layout: fixed"> <tr style=" padding:0px;"> <td style="width:48px; padding:0px;"> <asp:image id="imguser" runat="server" imageurl="~/media/user_anon.png" cssclass="userimage" /> </td> <td class="customcell"> <asp:label id="lbluser" runat="server" text="label">logged in</asp:label> <asp:image id="image1" runat="server" imageurl="~/media/dropdown.png" /> </td> </tr> </table> </td>
css:
.customtable { font-size:smaller; text-align:center; border-collapse: collapse; } .userimage { margin:0px; }
well think found problem , made 2 fiddle test, first example:
it's problem, right?
now one:
you need set display: block
img
#imguser { width: 100%; display: block; margin: 0; }
Comments
Post a Comment