how can i get the images and the content to the right to top align? i tried valign="top" as you can see.
<table border="0" cellspacing="0" cellpadding="0"> <tbody> <tr valign="top"> <td valign="top"><img alt="" style="border: 0px solid;" src="/Portals/0/affiliates/NFL.png" /></td> <td valign="top"> </td> <td valign="top" style="padding-left: 10px;"><strong><span class="cnt5_heading" style="color: #c00000;">NFL</span><br /> </strong><span class="body_copy" valign="top">The official website for the National Football League. <a href="http://www.nfl.com/" target="_blank">Learn more >></a></span></td> </tr> <tr valign="top"> <td> </td> <td> </td> <td> </td> </tr> <tr valign="top"> <td valign="top"><img alt="" src="/Portals/0/affiliates/NFL_players_association.png" /></td> <td> </td> <td valign="top" style="padding-left: 10px;"><strong><span class="cnt5_heading" style="color: #c00000;">NFL Players Association</span><br /> </strong><span class="body_copy" valign="top">"We, The National Football League Players Association ... Pay homage to our predecessors for their courage, sacrifice, and vision; ... Pledge to preserve and enhance the democratic involvement of our members; ... Confirm our willingness to do whatever is necessary for the betterment of our membership - To preserve our gains and achieve those goals not yet attained." <a href="http://www.nflplayers.com" target="_blank">Learn more >></a></span></td> </tr> <tr valign="top"> <td> </td> <td> </td> <td> </td> </tr> <tr valign="top"> <td valign="top"><img alt="" src="/Portals/0/affiliates/NFL_play_benfits.png" /></td> <td><strong> </strong></td> <td valign="top" style="padding-left: 10px;"><strong><span class="cnt5_heading" style="color: #c00000;">NFL Player Benefits</span></strong><br /> <span class="body_copy">A Complete guide to the benefits available for NFL players. <a href="http://nfla.davidhenryagency.com/BenefitsampServices.aspx" target="_self">Learn more >></a></span></td> </tr> <tr valign="top"> <td> </td> <td> </td> <td> </td> </tr> <tr valign="top"> <td valign="top"><img alt="" src="/Portals/0/affiliates/NFL_hall_fame.png" /></td> <td> </td> <td valign="top" style="padding-left: 10px;"><strong><span class="cnt5_heading" style="color: #c00000;">Pro football Hall of Fame</span></strong><br /> <span class="body_copy">The Mission of the Pro Football Hall of Fame is: To honor, preserve, educate and promote. <a href="http://www.profootballhof.com/default.aspx" target="_blank">Learn more >></a></span><br /> </td> </tr> </tbody> </table>
To place an item at the top or bottom of its cell, insert the "VALIGN=" attribute within the code for that cell. To vertically align an entire row (e.g., placing all data in that row at the tops of the cells), insert the "VALIGN=" attribute within the code for that row.
The HTML <td> valign Attribute is used to specify the vertical alignment of text content in a cell. Syntax: <td valign="top | middle | bottom | baseline"> Attribute Value: top: It sets the content to top-align. middle: It sets the content to middle-align.
Set the height and width of the cell to 200px . Apply the border of 2px solid #000 to the cells. Next, set the vertical-align property to top and text-align property to right . As a result, the contents of the cells are positioned right below the cell's border and to the right side.
Some CSS :
table td, table td * { vertical-align: top; }
<TABLE COLS="3" border="0" cellspacing="0" cellpadding="0"> <TR style="vertical-align:top"> <TD> <!-- The log text-box --> <div style="height:800px; width:240px; border:1px solid #ccc; font:16px/26px Georgia, Garamond, Serif; overflow:auto;"> Log: </div> </TD> <TD> <!-- The 2nd column --> </TD> <TD> <!-- The 3rd column --> </TD> </TR> </TABLE>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With