Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how come doesn't display correctly?

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
for some reason, both N4 and MSIE5.5 won't display this correctly. It forces a line break after every white space character. I only want the line breaks to appear where the <BR> is. Is there a CSS property that I need to use for this? I want the equivalent of a NOWRAP, but I know the white-space property isn't widely implemented, if it even is.

thanks for your help.
leo

------------code-------------
Code:
<style type=&quot;text/css&quot;>
<!--
.popUpMenu{
		visibility: hidden;
		position:	absolute;
		left:		320px;
		z-index:	519;
	}
.nestedMenu{
		visibility: hidden;
		position:	absolute;
		left:		360px;
		z-index:	520;
		}
.menuLink{
	background:		#CCCCCC;
	layer-background-color: #CCCCCC;
	color:			navy;
	}
-->
</style>

<div class=&quot;popUpMenu&quot; id=&quot;builMenu&quot;>
	<span class=&quot;menuLink&quot; id=&quot;buil1&quot; name=&quot;buil1&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil2&quot; name=&quot;buil2&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil3&quot; name=&quot;buil3&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil4&quot; name=&quot;buil4&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil5&quot; name=&quot;buil5&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil6&quot; name=&quot;buil6&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil7&quot; name=&quot;buil7&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil8&quot; name=&quot;buil8&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span><br>
	<span class=&quot;menuLink&quot; id=&quot;buil9&quot; name=&quot;buil9&quot;><a href=&quot;#&quot; onMouseOver=&quot;javascript:showMenu('builMenu')&quot; onMouseOut=&quot;javascript:hideMenu('builMenu');&quot;>building supplies</a></span>
</div>
 
not sure what you mean... i'm not getting odd line breaks. there will always be a line break after a div though, if that's what you mean. jared@aauser.com -
 
what's happening is that a line break is getting inserted with every space character.
so for example:

&quot;building supplies&quot;
appears as

&quot;building
supplies&quot;

i'm trying to make this into a pop-up menu, and if I can't control these line breaks, this is going to be a lot harder than I thought.

thanks
leo
 
This is quite simple. In all the cases where you don't want to have a lin break you have to replace space with &amp;nbsp; (special symbol for non-breaking space). For example, replace &quot;building supplies&quot; with &quot;building&amp;nbsp;supplies&quot; (make sure there is no space between &amp;nbsp; and adjacent words).

I hope it helped.

---
---
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top