Home
TeamSite
using line-break="BR"
ttriemst
Hello,
I was wondering if anyone has been able to get the line-break to work in the <textarea> tag? The following line is from my DCT:
<textarea cols="65" rows="7" rtf="t" line-break="BR" required="f" />
I am trying to use this to handle line breaks. For instance, in the template text area, I enter in the following:
This is line one
This is line two
When I save and do a preview, it shows up as:
This is line one This is line two
It is ignoring the line breaks. I am using the web browser interface, and am running TS552 on Solaris 2.8. Any help would be appreciated. Thanks
Find more posts tagged with
Comments
Jens
I tried this in browser-UI and can't get it working too, but in java ui it works.
So, i think the line-break attribut is only working in Java UI.
Ciao,
Jens
Adam Stoller
I don't believe that 'rtf' or 'line-break' are valid textarea attributes [any more] - however you might be able to do what you want with VF fields (I believe you can configure whether hard-returns insert paragraph tags or line-break tags)
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
JonathonG
Another option is to do the following in your pt (untested code, but should be pretty close):
<iw_perl>
my $text = iwpt_dcr_value('/path/to/textarea');
$text =~ s/\n/<BR>\n/g;
iwpt_output($text);
</iw_perl>
Jonathon
Independent Interwoven Contractor
gzevin
yes, you;re right. that's usually the way of cleaning things up
Greg Zevin, Ph.D. Comp. Sc.
Independent Interwoven Consultant/Architect
Sydney, AU
Frederik
Actually, the manual clearly states that this linebreak= only works for textareas of type rtf="t". And rtf textareas only work in Java Templating client.
Reference : tst.552.dev.pdf page 50
grts.
ttriemst
Thanks for the help, the code you provided works great.