Glyph - XML Fallback

Sure Textile and Markdown are great, but sometimes you may want to just use HTML, without the extra verbosity, of course. Take tables for example: Textile offers an easy way to create them, but things may get dirty when you need to have multiple paragraphs or lists within cells.

Very early versions of Glyph used to offered some simple table, tr, tr, td macros just for that. Of course the problem was that thy didn't offer any way to customize the markup by adding, for example, CSS classes.

Instead, by default, Glyph can convert any unrecognized macro to the corresponding XML element and macro attributes to XML attributes.

Basically, if the options.xml_fallback setting is set to true, any macro unknown to Glyph with at most one parameter will be converted to an XML tag with the same name and any attribute will be converted to the corresponding XML attribute.

Additionally, it is possible to force macro-to-XML conversion by composing the name of a tag with the xml macro, so for example xml/snippet[test] will be converted into <snippet>test</snippet>.

Blacklisted XML tags

By default, the following tags are blacklisted and will be ignored:

  • applet
  • base
  • basefont
  • embed
  • frame
  • frameset
  • iframe
  • isindex
  • meta
  • noframes
  • noscript
  • object
  • param
  • title