[Zope] html space( ) in string

Jos van der Vleuten Jos.van.der.Vleuten@transiciel.nl
Tue, 25 Mar 2003 17:20:22 +0100


This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C2F2EA.6F954DC0
Content-Type: text/plain;
	charset="iso-8859-1"

chr(38) is also rendered as &

regards,
Jos van der Vleuten

-----Original Message-----
From: Passin, Tom
To: Jos van der Vleuten; zope@zope.org
Sent: 25-3-2003 16:28
Subject: RE: [Zope] html space( ) in string

[Jos van der Vleuten]

> The following code-snippet: 
>        global space python:[' ;']; 
>        global str_html_space python:space[0]*new_len_title; 
> would be rendered in html as: ........... ........ 
> How can i solve this so that it will render a correct html space
( )? 

use chr(38) for the ampersand -

chr(38) + 'nbsp;']

Cheers,

Tom P

------_=_NextPart_001_01C2F2EA.6F954DC0
Content-Type: text/html;
	charset="iso-8859-1"

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2653.12">
<TITLE>RE: [Zope] html space(&amp;nbsp;) in string</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=2>chr(38) is also rendered as &amp;amp;</FONT>
</P>

<P><FONT SIZE=2>regards,</FONT>
<BR><FONT SIZE=2>Jos van der Vleuten</FONT>
</P>

<P><FONT SIZE=2>-----Original Message-----</FONT>
<BR><FONT SIZE=2>From: Passin, Tom</FONT>
<BR><FONT SIZE=2>To: Jos van der Vleuten; zope@zope.org</FONT>
<BR><FONT SIZE=2>Sent: 25-3-2003 16:28</FONT>
<BR><FONT SIZE=2>Subject: RE: [Zope] html space(&amp;nbsp;) in string</FONT>
</P>

<P><FONT SIZE=2>[Jos van der Vleuten]</FONT>
</P>

<P><FONT SIZE=2>&gt; The following code-snippet: </FONT>
<BR><FONT SIZE=2>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; global space python:['&amp;nbsp;;']; </FONT>
<BR><FONT SIZE=2>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; global str_html_space python:space[0]*new_len_title; </FONT>
<BR><FONT SIZE=2>&gt; would be rendered in html as: ...........&amp;amp;nbsp;........ </FONT>
<BR><FONT SIZE=2>&gt; How can i solve this so that it will render a correct html space</FONT>
<BR><FONT SIZE=2>(&amp;nbsp;)? </FONT>
</P>

<P><FONT SIZE=2>use chr(38) for the ampersand -</FONT>
</P>

<P><FONT SIZE=2>chr(38) + 'nbsp;']</FONT>
</P>

<P><FONT SIZE=2>Cheers,</FONT>
</P>

<P><FONT SIZE=2>Tom P</FONT>
</P>

</BODY>
</HTML>
------_=_NextPart_001_01C2F2EA.6F954DC0--