[Zope] Adding Carriage return/line feed to a text field

MCDONNELL, LARRY LARRY.MCDONNELL at new-haven.k12.ct.us
Fri Apr 22 09:28:10 EDT 2005


MCDONNELL, LARRY wrote:
 
> I have a form that the field length for that element is set to 65k in 
> the database. Using a textbox, the person can enter their information.
I 
> now want to view the text. I can again use a text box but what I want
to 
> do is this -
> 
> <dtml-var mytext>
  >
> If I use this format, the text is one line. Are there arguments or a 
> script that will add carriage return/line feed after you set the
parameters?
 
You can wrap it in HTML <pre> tags. This preserves formatting on layout.
 
Otherwise, you'll have to replace the newlines in your text with <br/> 
tags. Products.PythonScripts.standard.newline_to_br will do this for 
you, as will the newline_to_br attribute on the dtml-var tag. (You can 
find this in the Zope online help.)
 
               --jcc

 

Thanks for the help, it seems my company blocks lists so I did not get
your response until this morning when I checked the archives.

 

Thanks,

 

Larry McDonnell

Coordinator of Educational Technology

New Haven Public Schools

54 Meadow Street

New Haven, CT 06519

larry.mcdonnell at new-haven.k12.ct.us

(203) 946-2440

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/zope/attachments/20050422/04281e7f/attachment.htm


More information about the Zope mailing list