[UPHPU] PHP reading html

Brandon Stout bms at mscis.org
Wed Apr 4 10:56:37 MDT 2007


Daniel C. wrote:

> Yeah, that's the one you'll want to use then.  Much better solution,
> although parsing XML is almost as painful as parsing HTTP, but for
> different reasons.

I actually found it fairly easy to parse xml.  It took a little reading 
to see how to use xpath and such, but once I understood it, I found it 
relatively simple.  The php extensions you need:

  For PHP 4
    DOM XML:  http://us3.php.net/manual/en/ref.domxml.php
    PEAR's XML_Parser:  
http://pear.php.net/packages.php?catpid=22&catname=XML

  For PHP5
    DOM:  http://us3.php.net/manual/en/ref.dom.php
    SimpleXML:  http://us3.php.net/manual/en/ref.simplexml.php
    XMLReader:  http://us3.php.net/manual/en/ref.xmlreader.php
    XMLWriter:  http://us3.php.net/manual/en/ref.xmlwriter.php
    XSL:  http://us3.php.net/manual/en/ref.xsl.php

  For either one:
    SOAP:  http://us3.php.net/manual/en/ref.soap.php
    XML:  http://us3.php.net/manual/en/ref.xml.php
    XML-RPC (Experimental):  http://us3.php.net/manual/en/ref.xmlrpc.php
    XSLT:  http://us3.php.net/manual/en/ref.xslt.php

I wrote an article which I presented to UPHPU members on RSS parsing.  
You can find it here:

  http://mscis.org/?catID=110&artID=2&page=1

Brandon Stout
http://mscis.org


More information about the UPHPU mailing list