On Wed, 2008-08-20 at 19:34 +0200, Hermann Himmelbauer wrote:
Hi, I have a page template, that should have the characters "<" and ">" in the resulting HTML code, e.g.:
<input type="hidden", name="xyz", value="<ABC>" />
Zope3 makes a < / &rt; out of the "<>" characters:
<input type="hidden", name="xyz", value="<ABC&rt;"
Is there a way to get around this automatic conversion? I tried it via:
<input .... tal:attributes="value python:'<ABC>'" />
But this makes no difference.
Any clues?
Best Regards, Hermann
P.S.: I know, this seems to make no sense, but the page is a template for another, foreign application, which needs this specific values as placeholders and which I can not adapt...
My memory says and the HTML validator acknowledges it: this *is* broken. PT is designed to not do that. Here's how it *might* work: Take a view that generates the broken HTML snippet, like: class View: def code(self): return '<input value="<broken>"/>' And in your template do: <div tal:replace="structure view/code"/> I didn't test it and I'm not sure it works. It might, though. Christian PS: This makes the little internet elves cry. -- Christian Theune · ct@gocept.com gocept gmbh & co. kg · forsterstraße 29 · 06112 halle (saale) · germany http://gocept.com · tel +49 345 1229889 7 · fax +49 345 1229889 1 Zope and Plone consulting and development