Send to a Friend

Vincentt's avatar

How can I shrink a <div> to its content, while still having it centered?

Asked by Vincentt (8094points) October 29th, 2007

Hey, there’s this <div> I want to center on an HTML page but I don’t want it to take the full width… I could shrink it by adding float: left; but then it doesn’t center :(

Using Fluther

or

Using Email

Separate multiple emails with commas.
We’ll only use these emails for this message.