Re: FN-FORUM: Css horizontal alignment (mark II)
date posted 3rd September 2007 15:00
On 3 Sep 2007, at 15:21, John Deaville wrote:
>
>>
>> Looks fine on firefox, you might want (note the px):
>>
>> margin: 0px auto;
>> text-align: center;
>>
>> to cover most browsers.
>
>
> Thanks - will do
that will center all the text in the div you apply it too...
do:
body{
text-align:center
}
div#container{
width: 700px;
text-align: left;
margin: 0 auto
}
with:
Your content
for a centered 700px wide div with left aligned text in every browser...
;o)
(note you don't need the ; on the last declaration in each block, but
it's probably good practice to include it)