Skip to main content
Inspiring
February 27, 2015
Answered

bottom alignment in table cell isn't working

  • February 27, 2015
  • 1 reply
  • 396 views

So, I have a one row, 2 column table.  In the second/last column, I have an image that needs to be bottom and right aligned.  However, no matter what I do, I can't get the image to sit at the bottom of the cell.

If I add columns, and move the image to one of the inside columns, it bottom aligns, but if I then delete the column to the right (so that the image is now, again, in the last column) the image again is not bottom aligned.

I have tried giving the image a negative bottom margin, but that isn't working.

here's the code:

<td class="last" style="vertical-align: bottom;"><a href="#TOPofPage1"><img

   src="../RESOURCES/i_SPECIAL_art/RETURNtoTopIcon.png" alt="" class="TOPofPage"

   style="margin-bottom: -12px;" /></a></td>

here's what it looks like:

So the orange circle with the white triangle needs to be resting at the bottom of its column... why isn't it?

This topic has been closed for replies.
Correct answer Amebr

When I copy your cell code and just change the image to a plain triangle I have, the bottom alignment and negative margin work correctly.

Check other styling in the tr and table tags, and also any of the styles applied to any part of the table - maybe something there is setting the alignment of the cell.

If nothing looks obvious, perhaps copy the whole table to a fresh test project to see what happens, and gradually add back in your styles to see if you can reproduce.

1 reply

AmebrCommunity ExpertCorrect answer
Community Expert
March 2, 2015

When I copy your cell code and just change the image to a plain triangle I have, the bottom alignment and negative margin work correctly.

Check other styling in the tr and table tags, and also any of the styles applied to any part of the table - maybe something there is setting the alignment of the cell.

If nothing looks obvious, perhaps copy the whole table to a fresh test project to see what happens, and gradually add back in your styles to see if you can reproduce.

ktbFLAuthor
Inspiring
March 2, 2015

THANKS AMEBR.. i always forget that "put it in a new project thing!" lol