Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > How to verticllay align text in a div-box?

Reply
Thread Tools

How to verticllay align text in a div-box?

 
 
metalive
Guest
Posts: n/a
 
      07-17-2005
Hello!

I want to create a footer as a narrow line at the bottom of the screen
and am therefore using a div-box formatted with "height:25px;".

The line of text in it though, is aligned at the top the the footerbox,
and I've tried to get it vertically middled using
"vertical-align:middle;" on the the div-box, which didn't work. The next
thing I tried was to wrap the line of text into a <span> and then
applied the "vertical-align:middle;" on that, but neither did that work.

Can someone tell me the solution please?
THX
Nick
 
Reply With Quote
 
 
 
 
Spartanicus
Guest
Posts: n/a
 
      07-17-2005
metalive <> wrote:

>I want to create a footer as a narrow line at the bottom of the screen
>and am therefore using a div-box formatted with "height:25px;".
>
>The line of text in it though, is aligned at the top the the footerbox,
>and I've tried to get it vertically middled using
>"vertical-align:middle;" on the the div-box, which didn't work. The next
>thing I tried was to wrap the line of text into a <span> and then
>applied the "vertical-align:middle;" on that, but neither did that work.
>
>Can someone tell me the solution please?


Specify a top and bottom padding on the footer box.

--
Spartanicus
 
Reply With Quote
 
 
 
 
Neredbojias
Guest
Posts: n/a
 
      07-18-2005
With neither quill nor qualm, metalive quothed

> Hello!
>
> I want to create a footer as a narrow line at the bottom of the screen
> and am therefore using a div-box formatted with "height:25px;".
>
> The line of text in it though, is aligned at the top the the footerbox,
> and I've tried to get it vertically middled using
> "vertical-align:middle;" on the the div-box, which didn't work. The next
> thing I tried was to wrap the line of text into a <span> and then
> applied the "vertical-align:middle;" on that, but neither did that work.


Vertical-align must have some other text to relate to. For what you
want, my advice is to use a table.

--
Neredbojias
Contrary to popular belief, it is believable.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
<div align=center> also affects align of dynamic dropdown item text Steve Richter ASP .Net 1 06-24-2007 07:11 PM
left align within centre align Paul Lautman HTML 3 03-03-2006 02:45 PM
text-align vs align tshad HTML 1 06-23-2005 10:29 PM
Align text in text box acko bogicevic ASP .Net 4 01-09-2004 05:21 PM
how to Align text left & vertical align middle Kay ASP .Net 2 07-25-2003 08:32 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57