Align content to the left - how?

admin

Administrator
Staff member
I have a very background photo. The idea is that the site content will show up in the right side of the photo and There's going to be some white space on the side (for 1024 X 768).

I got this simple DIV and inside it I got all of the site content.

<div style="text-align: right; width: 780px;">
Site Content
</div>

The problem is that it's workin' fine on FF but on IE It's all aligned to the right side. It doesn't pay attantion to the 780px.

What can I do?

Thanks!We'll need to see more than that to be able to help you. It would be best if you could provide a link to the page.Like Kravvitz said, you are a little bit minimal with your information...

But this is what I thought you wanted to say:
- a picture aligned to the left so
- content merge to the right of it
- with a width of 780px;

If so I would do it like this:

CSS
#container
{
width: 90%;
margin: 10px auto;
background-color: #fff;
color: #333;
border: 1px solid gray;
line-height: 130%;
}

#leftnav
{
float: left;
width: 160px;
margin: 0;
padding: 1em;
background:url(putithere.jpg);
}

#content
{
margin-left: 200px;
border-left: 1px solid gray;
padding: 1em;
max-width: 36em;
}


<div id="container">
<div id="leftnav">
<p>
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut.
</p>
</div>
<div id="content">
<h2>Subheading</h2>
<p>
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi.
</p>
</div>


3Pinter
 
Back
Top