<footer> and cie.

Michel Fortin michel.fortin at michelf.ca
Fri Feb 8 16:38:28 EST 2013


Question: what should be the output for this:

> for me the point of having my blog as a static site is mainly easy deployment<br>
> I don't have to worry about even configuring PHP<br>
> I just put html on a web server and boom! instant win
>
> <footer>— [Igor Wiedler wins](https://igor.io)</footer>

The real question is how to treat `<footer>`. Is it a block-level element like `<div>`? That should mean that the content would be passed to the output literally. One thing for sure, it's not a span element, as the HTML spec forbids putting it inside a `<p>`. Perhaps is should be something in between. Many of the new HTML5 elements are in that same situation.

In PHP Markdown 1.0.1p I started treating them as block-level elements and they get the same treatment as `<div>`, but implementations don't seem to agree on this (and yes PHP Markdown Extra gives something that makes no sense):
http://johnmacfarlane.net/babelmark2/?normalize=1&text=%3E+for+me+the+point+of+having+my+blog+as+a+static+site+is+mainly+easy+deployment%3Cbr%3E%0A%3E+I+don't+have+to+worry+about+even+configuring+PHP%3Cbr%3E%0A%3E+I+just+put+html+on+a+web+server+and+boom!+instant+win%0A%3E%0A%3E+%3Cfooter%3E—+%5BIgor+Wiedler+wins%5D(https%3A%2F%2Figor.io)%3C%2Ffooter%3E%0A

I find it somewhat worrying that the reference tool (Markdown.pl) treats it as a span element. Well, I don't care that much about what old Markdown.pl does, but I do care about people trying it there on the dingus and finding that it works as they intended (if they only look at the rendered output, they won't see the mess in HTML tags), and then getting an unexpected and undesired result with other implementations.

Reference:
https://github.com/michelf/php-markdown/issues/67

--
Michel Fortin
michel.fortin at michelf.ca
http://michelf.ca/



More information about the Markdown-Discuss mailing list