99 | | * The `Markup` class in the [ApiDocs/GenshiCore genshi.core] module can be used to flag strings that should not be escaped. Strings wrapped in a `Markup` instance get copied to the output unchanged. |
100 | | * The `XML` and `HTML` functions in the [ApiDocs/GenshiInput genshi.input] module parse XML and HTML strings, respectively, and produce a [wiki:Documentation/streams.html markup stream]. Note that this option can be rather expensive, as the text needs to be parsed just to be serialized again. Also, this method fails on bad markup that cannot be parsed by either [http://docs.python.org/lib/module-HTMLParser.html HTMLParser] or [http://docs.python.org/lib/module-xml.parsers.expat.html Expat]. |
101 | | * If you are generating the snippets in question yourself, you may want to use the [ApiDocs/GenshiBuilder genshi.builder] to [wiki:Documentation/builder.html generate markup streams programmatically]. Just as the results of the `XML` and `HTML` functions discussed above, the stream produced using `genshi.builder` will not be escaped in the template output. |
| 99 | * The `Markup` class in the [wiki:ApiDocs/genshi.core genshi.core] module can be used to flag strings that should not be escaped. Strings wrapped in a `Markup` instance get copied to the output unchanged. |
| 100 | * The `XML` and `HTML` functions in the [wiki:ApiDocs/genshi.input genshi.input] module parse XML and HTML strings, respectively, and produce a [wiki:Documentation/streams.html markup stream]. Note that this option can be rather expensive, as the text needs to be parsed just to be serialized again. Also, this method fails on bad markup that cannot be parsed by either [http://docs.python.org/lib/module-HTMLParser.html HTMLParser] or [http://docs.python.org/lib/module-xml.parsers.expat.html Expat]. |
| 101 | * If you are generating the snippets in question yourself, you may want to use the [wiki:ApiDocs/genshi.builder genshi.builder] to [wiki:Documentation/builder.html generate markup streams programmatically]. Just as the results of the `XML` and `HTML` functions discussed above, the stream produced using `genshi.builder` will not be escaped in the template output. |