summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c3c844f)
raw | patch | inline | side by side (parent: c3c844f)
author | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Thu, 27 Sep 2001 06:45:58 +0000 (06:45 +0000) | ||
committer | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Thu, 27 Sep 2001 06:45:58 +0000 (06:45 +0000) |
on the plain() template function to escape the text for HTML.
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@258 57a73879-2fb5-44c3-a270-3262357dd7e2
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@258 57a73879-2fb5-44c3-a270-3262357dd7e2
roundup/htmltemplate.py | patch | blob | history | |
roundup/templates/extended/html/msg.index | patch | blob | history | |
roundup/templates/extended/htmlbase.py | patch | blob | history |
index de6f10de8c200c229f2ea923cc81fef7c62bd9eb..c073a75e9ea357d6fe95227a98a775cc47dc9dcc 100644 (file)
--- a/roundup/htmltemplate.py
+++ b/roundup/htmltemplate.py
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
#
-# $Id: htmltemplate.py,v 1.23 2001-09-10 09:47:18 richard Exp $
+# $Id: htmltemplate.py,v 1.24 2001-09-27 06:45:58 richard Exp $
import os, re, StringIO, urllib, cgi, errno
for a Link or Multilink property, display the key strings of the
linked nodes (or the ids if the linked class has no key property)
'''
- def __call__(self, property):
+ def __call__(self, property, escape=0):
if not self.nodeid and self.form is None:
return '[Field: not called from item]'
propclass = self.properties[property]
value = ', '.join([linkcl.get(i, k) for i in value])
else:
s = 'Plain: bad propclass "%s"'%propclass
+ if escape:
+ return cgi.escape(value)
return value
class Field(Base):
#
# $Log: not supported by cvs2svn $
+# Revision 1.23 2001/09/10 09:47:18 richard
+# Fixed bug in the generation of links to Link/Multilink in indexes.
+# (thanks Hubert Hoegl)
+# Added AssignedTo to the "classic" schema's item page.
+#
# Revision 1.22 2001/08/30 06:01:17 richard
# Fixed missing import in mailgw :(
#
index b7bdfa709e87b485d1227d363ffb8d788729e766..4331e270a388f01eac8051afa418afc815541025 100644 (file)
-<!-- $Id: msg.index,v 1.2 2001-09-27 06:36:42 richard Exp $-->
+<!-- $Id: msg.index,v 1.3 2001-09-27 06:45:58 richard Exp $-->
<tr class="row-hilite">
<property name="date">
<td><display call="link('date')"></td>
</property>
</tr>
<tr bgcolor="ffeaff">
- <td colspan=2><xmp><display call="plain('content')"></xmp></td>
+ <td colspan=2><pre><display call="plain('content', escape=1)"></pre></td>
</tr>
index 45bb7bac6ad78193b734e8d8d0b27dfca734b569..bee173eb01d0925a32fb2f4e7c6c10611dfe6c9f 100644 (file)
</property>
</tr>
<tr bgcolor="ffeaff">
- <td colspan=2><xmp><display call="plain('content')"></xmp></td>
+ <td colspan=2><pre><display call="plain('content', escape=1)"></pre></td>
</tr>
"""