On Jan 2, 2007, at 12:40, A. Pagaltzis wrote:

* Henri Sivonen <[EMAIL PROTECTED]> [2007-01-02 01:35]:
I hadn't thought that Atom was supposed to use innerHTML
parsing. I'd have said that you prepend
"<!DOCTYPE html><title></title><div>" to what travels in the
feed and append "</div>" to it,  parse the resulting string and
grab the first div in the document order.

That will lead to silent data loss if the content is malformed
such that it contains an extraneous `</div>`.

Good point.

Prepending <!DOCTYPE html><title></title> and grabbing the contents of body would work better.

--
Henri Sivonen
[EMAIL PROTECTED]
http://hsivonen.iki.fi/


Reply via email to