Bugfix while displaying content of textarea-entered text (Strings with format=String.TEXT): for displaying again textarea content, I replaced 'backslash n' with html br tags, but in some cases carriage returns are stored as a sequence of 'backslah r' and 'backslah n' chars. In this case, 'backslash r' chars were left alone in the HTML page, producing sometimes strange behaviour within the browser.
This commit is contained in:
parent
3fc5bc8418
commit
39321b2d38
5 changed files with 25 additions and 12 deletions
|
@ -13,7 +13,7 @@
|
|||
</span>
|
||||
<tal:formattedString condition="python: fmt not in (0, 3)">
|
||||
<span tal:condition="python: value and (fmt == 1)"
|
||||
tal:replace="structure python: value.replace('\n', '<br>')"/>
|
||||
tal:replace="structure python: contextObj.formatText(value, format='html')"/>
|
||||
<span tal:condition="python: value and (fmt == 2)" tal:replace="structure value"/>
|
||||
</tal:formattedString>
|
||||
</metal:view>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue