SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    ********* Ornithologist AtomicPenguin's Avatar
    Join Date
    May 2002
    Location
    Vancouver, BC
    Posts
    459
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    XML parsing script for PHP4 and 5 on ALL systems

    Hey folks,

    I develop a few open source PHP apps that (should!) run on virtually any system, PHP 4 or 5. In my own work I've used SimpleXML, XML Parser and other libraries, depending on what's available on the server. But for my open source apps, I've shied away from storing content in XML files because there doesn't seem to be one consistent way to parse XML on ALL systems in PHP. Some have this library installed, some that, some none at all.

    But I can't put it off any more...

    Has anyone in a similar boat come across One XML Parser To Rule Them All? It can be extremely basic: compatibility with all server configurations trumps all other considerations. Obviously it would be a downloadable library that I could bundle with my own scripts.

    Thanks!

    - Ben
    A.P.

    generatedata.com - free JS/PHP/MySQL random test data generator.
    Form Tools - free PHP/MySQL form processor.

  2. #2
    SitePoint Wizard silver trophybronze trophy Cups's Avatar
    Join Date
    Oct 2006
    Location
    France, deep rural.
    Posts
    6,869
    Mentioned
    17 Post(s)
    Tagged
    1 Thread(s)
    I hesitate to say it, but did you look in PEAR and in phpclasses.org? If not try searching through Google Code with the switch langhp

  3. #3
    @php.net Salathe's Avatar
    Join Date
    Dec 2004
    Location
    Edinburgh
    Posts
    1,396
    Mentioned
    61 Post(s)
    Tagged
    0 Thread(s)
    You're probably wanting to fall back on the xml_* family of functions. As Cups suggested, there will be classes around (for example to parse XML into an array/object structure) written for old versions of PHP.
    Salathe
    Software Developer and PHP Manual Author.

  4. #4
    . shoooo... silver trophy logic_earth's Avatar
    Join Date
    Oct 2005
    Location
    CA
    Posts
    9,013
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    Why not join the goPHP5 movement? Why continue support for the discontinued PHP4?
    http://gophp5.org/
    Logic without the fatal effects.
    All code snippets are licensed under WTFPL.



Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •