> From: joshua hough
> This is a <span> set within the <div> 
> that contains the blue tabs.  The <div> is text-align: left 
> and fills the width of its parent.  I'd like to center the 
> date in the remaining 19px by 160px blue space to the right 
> of the last tab.  It refuses to be 160px wide or 19px tall.  
> Making it a <div> pushes it below the tabs.

Joshua,

text-align isn't applicable to a span or other inline elements.


As you note using a block level element like div places the content
below your other block level element.
Even if you set the span to display: block and text-align: center
you'll find that the centered span appears on a line by itself.

The problem is what is the container that you want the span centered
in? How is something centered when it is part of some text that is
flowed in a block level element?

You probably need to rethink your design/layout and see if there is
another way to achieve what you want to do with the layout of this
content.

Maybe float the "nav" div left and put the date in its own div
that could then sit to the right of "nav if you set a large left
margin on it. Or set the date in a paragraph or div and float it
right.

-- 
Peter Williams
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to