Thanks for the quick reply. This question may be beyond the scope of this mailing list, but...
I am pulling data from a database view that adds spaces to create alignment. For example: * AZ300~30ST Full-Width Std Thic AZ300~18ST Full-Width Std Thic * AZ360HD~36HD 20in Tandem St AZ360HD~20HD 20in Tandem St AZ360HD~24Z 20in Tandem St I am replacing the leading spaces before writing the data to a select box's option tag. I tried adding style="white-space: pre;" to the option tag, but that made all the new line characters show up. I tried putting a div tag, with style="white-space: pre;" around the contents of the option tag. That didn't have any effect. <select name="partid"> <option value="AZ300R2F3S2"> <div style="white-space: pre;">* AZ300~30ST Full-Width Std Thic (AZ300R2F3S2)</div> </option> <option value="X000564"> <div style="white-space: pre;"> AZ300~18ST Full-Width Std Thic (X000564)</div> </option> </select> I am sure there are other solutions, but is the first thing that came to mind. Matt On Fri, 2007-03-30 at 18:22 -0400, Sam Tregar wrote: > On Fri, 30 Mar 2007, Matt Taylor wrote: > > > I couldn't find this information in the archive... > > > > I like the ESCAPE options (HTML, URL, JS). > > > > Is there a way to also escape whitespace? In particular, I would like > > an easier way to replace spaces with > > > > Currently looping through data from dbi and replacing. Any ideas? > > Don't do that? really shouldn't be needed in modern HTML > layout. Maybe you can show us what you're using it for and we can > suggest a better way? > > -sam ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Html-template-users mailing list Html-template-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/html-template-users