[ANN] PHP Markdown 1.0.2b7
gruber at fedora.net
Sun Sep 17 19:11:03 EDT 2006
Michel Fortin <michel.fortin at michelf.com> wrote on 9/16/06 at 5:23 PM:
> Another big change is the automatic hashing of all Markdown-generated
> HTML content. Previous versions of PHP Markdown Extra were already
> doing this, but it was limited on block-level elements only and was
> done to have less call to make to the expensive html block parser.
> This has been ported to the more basic PHP Markdown, and in addition
> to hashing block-level content it now also hash span-level elements:
> this has the benefit of preventing bad nesting of elements, so
> something like this:
> *Some **strange* emphasis**
> will now give valid HTML:
> *Some <strong>strange* emphasis</strong>
That's interesting, and because the output is valid, it's probably
better than what Markdown.pl currently generates.
I've been thinking that a better solution for input like that
would be to generate markup like this:
<em>Some <strong>strange</strong></em><strong> emphasis</strong>
Which is more of a "do what I mean" solution. However, I've given
no thought whatsoever to how this would be done algorithmically.
> * Made the block-level HTML parser smarter using a
> specially- crafted regular expression capable of handling
> nested tags.
A single pattern that matches nested tags?!
$me == "downloading now";
More information about the Markdown-Discuss