Re: NU’s polyglot possibilities (Was: The non-polyglot elephant in the room)

Alex Russell writes:

> I find myself asking (without an obvious answer): who benefits from
> the creation of polyglot documents?

I can see an advantage of the creating a snippet as polyglot HTML/XHTML.
For example if you want to distribute a badge or banner or status widget
or search form or something that others can paste into their sites, it's
simpler if you can just offer a single snippet which will work fine when
pasted into either an HTML or an XHTML document.


* The number of sites served as XHTML is so small that this may not be
  worth bothering with.

* This scenario doesn't involve an entire document being polyglot. So if
  we wanted to support it we'd actually need a spec and validator for
  polyglot snippets, rather than entire documents.

* You can't quite get this right in all detail anyway. For example,
  suppose your snippet includes a <table>, and you want it to be styled
  by an enclosing site's style-sheet to match other <table>-s on the
  site. Do you include <tbody> tags or not? If the enclosing site is
  XHTML then its styles may depend on either the presence of or the
  absence of <tbody> elements. In order to match your snippet needs to
  do the same -- but obviously you can't produce a single snippet which
  both includes and omits <tbody> tags, so you can't cover both
  possibilities anyway.


Received on Saturday, 26 January 2013 16:32:19 UTC