Click here to get back home

Stop text from wrapping in span

 HomeNewsGroups | Search

comp.infosystems.www.authoring.html - discuss HTML authoring here 

get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Stop text from wrapping in span Web Team @ Borough of Poole 09-28-2005
Posted by Web Team @ Borough of Poole on September 28, 2005, 2:51 am
Please log in for more thread options


Hi All,

I'm trying to stop text from wrapping in a span, so that my users can
enter content with out the box stretching across the screen when they
reach the edge of it, and with out horizontal scroll bars appearing.
Basically replicating notepad with word wrap switched on.

Maybe this isnt possible?

Any help will be much appreciated.

Simon.

--

Heres my code so far:

show/hide quoted text
.editorspan{
        position: relative;
        height:200px;
        width:200px;
        overflow-y : none;
        overflow-x : none;
        border: 4px groove #D3D3D3;
        background-color : white ;
        background:white;
}
show/hide quoted text


Posted by Leif K-Brooks on September 29, 2005, 4:04 am
Please log in for more thread options


Web Team @ Borough of Poole wrote:
show/hide quoted text

Do you have a question about Web authoring?

Posted by Web Team @ Borough of Poole on September 30, 2005, 11:39 pm
Please log in for more thread options


Yes, please see my original post.

Thanks.


Posted by Rincewind on October 1, 2005, 9:34 am
Please log in for more thread options


On 28 Sep 2005 02:51:59 -0700, Web Team @ Borough of Poole wrote:

show/hide quoted text

What is the question, the code you have given is at odds with the question,
show/hide quoted text
opposites.

The code is for a box 200x200 not an input field, I suggest you clarify the
question.

Posted by Web Team @ Borough of Poole on October 6, 2005, 6:00 am
Please log in for more thread options


Ok, my mistake, I'm actually trying to make text WRAP in a span, the
same way that notepad does when word wrap is on.

Irrelevant. you'll notice that my div has a CONTENTEDITABLE attribute,
which makes it editable by the user.

Since my first post I have noticed that this is only a problem if the
user types a string of text with no spaces in, in which case the div
either stretches across the page, or gives horizontal scroll bar,
depending on the overflow-x value. If the user is typing as normal (e.g
word after word!) then the wrapping occurs as expected.

Thanks,
Simon.


Similar ThreadsPosted
URGENT HELP: Text wrapping inside DIV. March 6, 2006, 11:25 pm
Preformatted text and line wrapping July 6, 2006, 2:22 pm
Truncating text in a table rather than wrapping to a new line? March 21, 2007, 5:07 pm

tag not wrapping

January 13, 2007, 10:06 pm
Wrapping an Image! March 27, 2007, 7:57 am
Example of DIV wrapping problem February 29, 2008, 10:37 pm
Does caps in table cause none wrapping May 2, 2008, 3:40 am
FF and IE with span February 6, 2007, 1:46 pm
a name vs. span id? May 26, 2008, 2:27 pm
problem with April 28, 2005, 12:23 am

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Driving a better car - Fuelzilla.com

Cabling site for homeowners and pros alike - Cabling-Design.com

Friends:

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap
Privacy Policy