Why is css doing this to me?
March 10, 2007 4:13 PM   Subscribe

I've run into a problem with displacing a block of text with css. II see the same behavior in IE6, IE7 and Firefox, so I gather its supposed to behave that way, but I can't work out why.

I'd like to be able to have some text included with the main content in the code, but pulled over to the margin, as in marginalia or the cornell note-taking method on display. I've worked out how to float the text, but when I shift it over into the margin, the main text continues to wrap around the (now empty) displaced area.

My sample document is here. Look to the left of the second or third excerpts in the maginalia column to see the empty blocks.

Why is it doing that? Can I make it stop, or have I chosen the wrong method of doing this to start with?
posted by Karmakaze to Computers & Internet (3 answers total)
 
Best answer: scholia {layout.css (line 87)
border:1px solid red;
float:right;
font-family:trebuchet,arial,helvetia,sans-serif;
font-size:x-small;
font-style:italic;
line-height:1.1em;
margin-left:-300px;
padding:5px;
position:relative;
right:-300px;
text-align:justify;
width:282px;
}

you forgot margin-left: -300px to counteract the right -300px
posted by Señor Pantalones at 4:48 PM on March 10, 2007


oops, remove "layout.css (line 87)". firebug info from the copy/paste
posted by Señor Pantalones at 4:49 PM on March 10, 2007


Response by poster: Thank you! I knew it had to be something obvious I just wasn't seeing.
posted by Karmakaze at 5:26 PM on March 10, 2007


« Older Customer injuries in employee only areas   |   Close Encounters of the YouTube kind. Newer »
This thread is closed to new comments.