Re: xml

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Andy Pieters wrote:
Hi all

I recently decided to switch to xml for the configuration of our programs.

I am now looking for a good way to handle that xml data.

Basically, what I am looking for is a functionality where I say

Get tag x with attribute1=y, attribute2=z,..., read its contents and put it in an associative array.


If you want that much granular detail then you might want to use XPATH. The syntax is obviously a little different than PCRE, but once you understand it you'll find it's much more efficient (and easier) than building monstrously large PCRE's.


http://php.net/manual/en/function.dom-domxpath-query.php
http://www.w3.org/TR/xpath#path-abbrev

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux