[plt-scheme] reading HTML as XML

From: Robby Findler (robby at cs.uchicago.edu)
Date: Fri Dec 12 11:27:32 EST 2008

The docs do say that read-html-as-xml produces a list of content.
Probably because there can be multiple html expressions in a single
input stream.

But I agree that it seems like xml->xexpr should signal an error. Its
documented contract even suggests it should, but I'm reluctant to
change it, not knowing how it is used ...?


On Fri, Dec 12, 2008 at 10:05 AM, Prabhakar Ragde <plragde at uwaterloo.ca> wrote:
> Matthew Flatt wrote:
>> I've run into this before. The `read-html'as-xml' function produces a
>> list of content values, and `xml->xexpr' wants a single content value.
>> So, you probably want to `map xml->xexr'. (I'm not sure why
>> `xml->xexpr' doesn't complain when it's given a list.)
> That works, thanks. I would never have thought to try it. --PR
> _________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme

Posted on the users mailing list.