brothercake
10-29-2002, 11:13 PM
I'm not sure if this is actually the right forum though, because its about php as well. Please move it if necessary.
Anyway ... what this application does is parse an XML document with PHP (using exim), turning into an array which is then sorted, searched through and returns results. I'm using it to archive a publications index; you can see it working here (http://www.brothercake.com/Ref/MORI_XML/articles.phtml).
With every query it has to parse the xml document, conditionally based on input criteria specifying attribute or node values; the document is 160k and contains around 700 entries. If you do a "search within text" it additionally goes to a remote search engine, returns the search results in the form of urls, which are then compared with the <url> tags in the xml document.
All fine and dandy. It works. But what I'm wondering is slightly incredelous ... is this all just ridiculously inefficient? Would I be better off doing with a database?
Anyway ... what this application does is parse an XML document with PHP (using exim), turning into an array which is then sorted, searched through and returns results. I'm using it to archive a publications index; you can see it working here (http://www.brothercake.com/Ref/MORI_XML/articles.phtml).
With every query it has to parse the xml document, conditionally based on input criteria specifying attribute or node values; the document is 160k and contains around 700 entries. If you do a "search within text" it additionally goes to a remote search engine, returns the search results in the form of urls, which are then compared with the <url> tags in the xml document.
All fine and dandy. It works. But what I'm wondering is slightly incredelous ... is this all just ridiculously inefficient? Would I be better off doing with a database?