简体   繁体   中英

Align the text to middle of div

Basically I am trying to align the "View Full Article (0 Comments)" text to the middle of the arrow in the dark blue div on the below linked page.

I have tried line height and that doesn't work. Any ideas?

http://www.prxa.info/

It depends on how fancy you want to get, I would just use relative/absolute positioning here, so this does the trick

.articles-bottom { position: relative; }

.articles-bottom a { left: 30px; position: absolute; top: 7px; }

That should do it.

try applying following to your a tag:

.articles-bottom a
{    
   vertical-align: middle;
   line-height: 2em;
   float: left; 
}

and for img inside div

img{
    float:left;
}

hope this helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM