Reply to Re: Anchor tag - vertical align text

Your name:

Reply:


Posted by Jonathan N. Little on 04/23/06 18:05

bmistiaen@yahoo.com wrote:
> Hi,
>
> I'm trying to create an anchor tag (link) with a height of 100px and a
> width of 100px.
> When the mouse is over it, i want the whole box (not just the link
> text) to have a red background.
>
> The problem is that i can't get the text in the anchor tag to vertical
> align to the middle.
> It is always on the top.
>
> I know it could be done with the property line-height.
> If you add "line-height: 100px;" to the a tag in the style
> definitions, then the text is centered.
> But what if you have 2 lines of text?
> Then it doesn't work anymore.
>
> Any ideas on how to do this?
<snip>

add 'display: block;'


--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация