|
| |
|
|
jeffw
Posts: 3 Joined: 1/24/2004 Status: offline
|
aaarrrggghhh! text overflowing a simple div help! - 3/11/2004 19:42:45
OK, i have a very simple absolutely positioned div that has a specified width and height. I have text overflowing this horizontally, without automatically breaking lines and staying within the boundaries of the div. This goes against all of my experience w/ CSS and the behavior div/spans and anything that contains text. It seems like I have tried eveything, but nothing works. In IE/WIN, the div expands to hold the text. In MOZ, the div stays the proper size, but the text just overflows to the right. I'm stuck! Any help appreciated! <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> <head> <link rel="stylesheet" href="global.css" type="text/css" media="screen" /> </head> <body> <div id="crap">aaaaaaaaaaaaaaaaaaabbbbbbbbbbbbbbbbbbbbbbbb</div> </body> </html> ----------------------------- #crap {position: absolute; top: 100px; left: 125px; width: 100px; height: 400px; border: 1px solid #000;}
|
|
|
|
Nancy
Posts: 3626 Joined: 11/9/1999 From: Nebraska Status: offline
|
RE: aaarrrggghhh! text overflowing a simple div help! - 3/12/2004 0:38:27
If this is the text you're working with, I would assume it can't do much else except stretch the div wider, as it has no way to break the word. Try using what would be considered normal length words and see how that goes. Very few words used would ever be that many characters, with no spaces. Nancy
_____________________________
Easy Estimates -- is a simple to use tool to quickly build a Web site page enabling visitors to quickly and easily create an estimate of the cost of services that you provide.
|
|
|
|
d a v e
Posts: 4071 Joined: 7/24/2002 From: England (but live in Finland now) Status: offline
|
RE: aaarrrggghhh! text overflowing a simple div help! - 3/12/2004 1:11:24
if you need some dummy text this is the classic http://www.lipsum.com/ (scroll down a bit and you can choose how many paragraphs, etc
_____________________________
David Prescott Gekko web design
|
|
|
|
Giomanach
Posts: 6090 Joined: 11/19/2003 From: England Status: offline
|
RE: aaarrrggghhh! text overflowing a simple div help! - 3/12/2004 3:29:30
The usual command for overflow on div layers is: overflow:hidden; It can have auto or hidden in it. But with regards to the problem at hand, the width is: width: 100px; Too short. The word if longer than 100 pixels should go onto the next line. try dropping a text size or making the div wider
< Message edited by Giomanach -- 3/12/2004 8:31:54 >
_____________________________
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|