I want to be able to return an HTML comment from a ZPT object. The purpose of this comment is to contain technical error messages that will be hidden from the normal user but available to those who need it. The idea is much like zope's error pages that put a stack trace inside an HTML comment. The problems I'm running into are : 1) ZPT doesn't expand TAL statements inside an HTML comment 2) Other means of generating the comment tags result in html-quoting the commend tag which causes the browser to render it as normal text. I've tried the following : <span tal:replace="python:'<!--'"> </span> <span tal:replace="python:'\x3c!--'"> </span> How might I achieve the desired effect? TIA, -D -- Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge Him, and He will make your paths straight. Proverbs 3:5-6 GnuPG key : http://dman.ddts.net/~dman/public_key.gpg
dman wrote:
<span tal:replace="python:'<!--'"> </span>
How might I achieve the desired effect?
<span tal:replace="structure string:<!--"></span> This is a comment <span tal:replace="structure string:-->"></span> Yes, it looks unlikely, but I've tested it :-) Cheers, Evan @ 4-am
On Wed, May 22, 2002 at 09:33:46PM -0500, Evan Simpson wrote: | dman wrote: | > <span tal:replace="python:'<!--'"> </span> | > | >How might I achieve the desired effect? | | <span tal:replace="structure string:<!--"></span> | This is a comment | <span tal:replace="structure string:-->"></span> | | Yes, it looks unlikely, but I've tested it :-) It does work. Thanks! I don't think I've seen that "structured" argument mentioned in the book. Did I just miss it or is not documented (there)? -D -- Through love and faithfulness sin is atoned for; through the fear of the Lord a man avoids evil. Proverbs 16:6 GnuPG key : http://dman.ddts.net/~dman/public_key.gpg
participants (2)
-
dman -
Evan Simpson