Div overflow problem.

HTML, CSS and anything else that deals with client side capabilities.

Moderator: General Moderators

Post Reply
User avatar
techkid
Forum Commoner
Posts: 54
Joined: Sat Sep 05, 2009 11:18 pm
Location: Maldives

Div overflow problem.

Post by techkid »

Hii.

This is a snapshop from the Design view of Adobe Dreamwaver CS5
Image

Here is the code:

Code: Select all

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style type="text/css">
#test{
	width:500px;
	margin:0 auto;
}
</style>
</head>

<body>
<div id="test">
ssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss
</div>
</body>
</html>
I dont want the text to overflow. I want it to go to the next line without using "<br />" tag.
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Re: Div overflow problem.

Post by s.dot »

[text]#test{
width:500px;
margin:0 auto;
overflow: auto;
}[/text]
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
User avatar
Eran
DevNet Master
Posts: 3549
Joined: Fri Jan 18, 2008 12:36 am
Location: Israel, ME

Re: Div overflow problem.

Post by Eran »

add 'word-wrap:break-word;' to your div styles.
Post Reply