HTML to XML call

Discussion in 'XML' started by joeraymond@gmail.com, May 2, 2007.

  1. Guest

    Hi,

    I am trying to figure out if it would be possible to write an app that
    could visit certain website, obtain the relevant data from those pages
    and convert it into a readable XML file.

    All I would like to know is how would I go about starting this task,
    and any advice comments anyone has on it.

    Regards


    Joe
     
    , May 2, 2007
    #1
    1. Advertising

  2. The W3C's "tidy" tool can rewrite (potentially broken) HTML into XHTML,
    which is an XML-based dialect of HTML.

    There are also HTML parsers available whose output is the standard W3C
    APIs such as SAX and DOM, and thus compatable with XML tooling. NekoHTML
    is one such, leveraging the Apache Xerces parser framework.


    --
    Joe Kesselman / Beware the fury of a patient man. -- John Dryden
     
    Joseph Kesselman, May 2, 2007
    #2
    1. Advertising

  3. Pavel Lepin Guest

    <> wrote in
    <>:
    > I am trying to figure out if it would be possible to write
    > an app that could visit certain website, obtain the
    > relevant data from those pages and convert it into a
    > readable XML file.


    What's the problem? Retrieve the document using your http
    library of choice, parse it using your HTML parser of
    choice, feed the DOM document to your XSLT processor of
    choice, serialize the resulting DOM document (using, well,
    your serializer of choice). Better yet, stuff the resulting
    DOM document into your XML database of choice. Heck, make
    it RDF/XML, stuff it into some SPARQL-aware storage and
    venture capitalists will be swarming all over you. I would,
    if I had a few million bucks I didn't need. Providing
    third-party semantics for all the meatbag-parsable content
    on the web will be quite an industry some ten years from
    now I think.

    Okay, scratch that, I'm just daydreaming. But the basic
    process for your task would be what I described indeed (the
    real heart of it would be an XSLT transformation that would
    suck the relevant data out of your source document,
    naturally).

    > All I would like to know is how would I go about starting
    > this task, and any advice comments anyone has on it.


    My professional opinion is that if you don't even know where
    to start, you're not really up for it. I hope you don't
    need it for anything serious--but it certainly would make
    an excellent exercise in many modestly exciting areas.

    --
    Pavel Lepin
     
    Pavel Lepin, May 3, 2007
    #3
  4. Andy Dingley Guest

    On 2 May, 15:52, wrote:

    > I am trying to figure out if it would be possible to write an app that
    > could visit certain website, obtain the relevant data from those pages
    > and convert it into a readable XML file.


    It's a staggeringly hard problem to solve. The tricky bit is that
    word "relevant".

    Otherwise it's trivial.
     
    Andy Dingley, May 3, 2007
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Monorom
    Replies:
    0
    Views:
    407
    Monorom
    Jul 29, 2003
  2. Fergus O'Shea

    HTML in XML call?

    Fergus O'Shea, Nov 21, 2003, in forum: XML
    Replies:
    4
    Views:
    486
    Fergus O'Shea
    Nov 26, 2003
  3. hagar
    Replies:
    1
    Views:
    383
    Simon Brooke
    Oct 19, 2006
  4. Fabio Mastria
    Replies:
    4
    Views:
    735
    Fabio Mastria
    Jan 28, 2008
  5. Erik Wasser
    Replies:
    5
    Views:
    465
    Peter J. Holzer
    Mar 5, 2006
Loading...

Share This Page