[Zope] newline_to_br without breaking source code
webmaster@winkelmaenner.de
webmaster@winkelmaenner.de
Fri, 15 Feb 2002 14:40:12 +0100
The rendered HTML sourcecode from zope always breaks the line, when
somebody wrote text in a textarea field and used several lines manually.
I can remove these "\n newlines" with javascript in the moment when
somebody sends his form but then i have no possibility to have them
back.
For example in a tag like <dtml-var textAreaInputWithLinebreak
newline_to_br>
But i want to use it also in a <a href> tag like this:
OnMouseOver="useUserTextAreaInput('<dtml-var
textAreaInputWithLinebreak>')"
and in 'normal' <dtml> tag like this:
<dtml-var textAreaInputWithLinebreak newline_to_br>
In the jacascript version the sourcecode will be broken without <br>
In the dtml version the sourcecode will also be broken but also with
<br>
The javascript version returns in every case an error.
thanks for help
harry
> Hi,
> I think I understand your problem, but not why you run into it.
>
> Why do you not just omit the newline_to_br part where you use it in
> Javascript?
>
> Mabe you do have to explain your problem a bit better:
> > Hello,
> >
> > i want to use a textarea form input in a java script and also in html
> tags.
> > Wenn i use the newline_to_br attribut it works fine in html, but it breaks
> the source code. This is no matter in html, but in javascript.
> >
> > In javascript i want only the but no linebreak.
> >
> > Does anybody has an solution for my problem ?
> > Thanks Harry