Bugfixes for IE.
This commit is contained in:
parent
3b9c078fbb
commit
b9dcc94bdb
|
@ -192,7 +192,7 @@ class AbstractWrapper(object):
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<!-- The user strip -->
|
<!-- The user strip -->
|
||||||
<tr height="33px">
|
<tr height="28px">
|
||||||
<td>
|
<td>
|
||||||
<table class="userStrip">
|
<table class="userStrip">
|
||||||
<tr>
|
<tr>
|
||||||
|
@ -259,7 +259,7 @@ class AbstractWrapper(object):
|
||||||
<tr height="26px" if="zobj and showPortlet and (layoutType != 'edit')">
|
<tr height="26px" if="zobj and showPortlet and (layoutType != 'edit')">
|
||||||
<td>:obj.pxNavigationStrip</td>
|
<td>:obj.pxNavigationStrip</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr valign="top">
|
||||||
<td>
|
<td>
|
||||||
<table width="100%" height="100%" cellpadding="0" cellspacing="0">
|
<table width="100%" height="100%" cellpadding="0" cellspacing="0">
|
||||||
<tr valign="top">
|
<tr valign="top">
|
||||||
|
|
|
@ -40,6 +40,8 @@ CUSTOM_CONVERSION_ERROR = 'Custom converter for "%s" values produced an ' \
|
||||||
'error while converting value "%s". %s'
|
'error while converting value "%s". %s'
|
||||||
XML_SPECIAL_CHARS = {'<': '<', '>': '>', '&': '&', '"': '"',
|
XML_SPECIAL_CHARS = {'<': '<', '>': '>', '&': '&', '"': '"',
|
||||||
"'": '''}
|
"'": '''}
|
||||||
|
XML_SPECIAL_CHARS_NO_APOS = XML_SPECIAL_CHARS.copy()
|
||||||
|
del XML_SPECIAL_CHARS_NO_APOS["'"]
|
||||||
XML_ENTITIES = {'lt': '<', 'gt': '>', 'amp': '&', 'quot': '"', 'apos': "'"}
|
XML_ENTITIES = {'lt': '<', 'gt': '>', 'amp': '&', 'quot': '"', 'apos': "'"}
|
||||||
HTML_ENTITIES = {
|
HTML_ENTITIES = {
|
||||||
'iexcl': '¡', 'cent': '¢', 'pound': '£', 'curren': '€', 'yen': '¥',
|
'iexcl': '¡', 'cent': '¢', 'pound': '£', 'curren': '€', 'yen': '¥',
|
||||||
|
@ -81,8 +83,9 @@ def escapeXml(s, format='xml', nsText='text'):
|
||||||
res = ''
|
res = ''
|
||||||
odf = format == 'odf'
|
odf = format == 'odf'
|
||||||
for c in s:
|
for c in s:
|
||||||
if XML_SPECIAL_CHARS.has_key(c):
|
if XML_SPECIAL_CHARS_NO_APOS.has_key(c):
|
||||||
res += XML_SPECIAL_CHARS[c]
|
# We do not escape 'apos': there is no particular need for that.
|
||||||
|
res += XML_SPECIAL_CHARS_NO_APOS[c]
|
||||||
elif odf and (c == '\n'):
|
elif odf and (c == '\n'):
|
||||||
res += '<%s:line-break/>' % nsText
|
res += '<%s:line-break/>' % nsText
|
||||||
elif odf and (c == '\r'):
|
elif odf and (c == '\r'):
|
||||||
|
@ -99,8 +102,8 @@ def escapeXhtml(s):
|
||||||
else:
|
else:
|
||||||
res = ''
|
res = ''
|
||||||
for c in s:
|
for c in s:
|
||||||
if XML_SPECIAL_CHARS.has_key(c):
|
if XML_SPECIAL_CHARS_NO_APOS.has_key(c):
|
||||||
res += XML_SPECIAL_CHARS[c]
|
res += XML_SPECIAL_CHARS_NO_APOS[c]
|
||||||
elif c == '\n':
|
elif c == '\n':
|
||||||
res += '<br/>'
|
res += '<br/>'
|
||||||
elif c == '\r':
|
elif c == '\r':
|
||||||
|
|
Loading…
Reference in a new issue