Kornel Lesiński wrote: on 14.10.2008 10:55:
>> prefix the content with the 'structure' keyword, it will use the value
>> verbatin.
>>
>> <script tal:content="structure myJsCode"></script>
> This may make XHTML ill-formed if there's any "<" or "&" in the script.
>
> <script>/*<![CDATA[*/
> ${structure myJSCode}
> /*]]>*/</script>
>
> works in both text/html and application/xhtml+xml modes.

It would be cool to have a "tal:cdata=" boolean value, where one could
switch on generation of CDATA wrapping automatically, so one could write:

<script tal:content="structure myJsCode" tal:cdata="true"></script>

And doesn't have to remember all kinds of required CDATA quoting.

Cheers,
Ernesto


_______________________________________________
PHPTAL mailing list
PHPTAL@lists.motion-twin.com
http://lists.motion-twin.com/mailman/listinfo/phptal

Reply via email to