Skip to content

How do I parse an XML file for a search?

Hi! I need to use PHP to create a search that will parse an XML file and return formatted information for an online store. Here is a link to the XML file if anyone is interested in taking this on!

http://store.surplusoutletinc.com/yhst-13261419795447/objinfo.xml

Thanks!

4 Comments

  1. Riyadh Hossain wrote:

    See the following PHP class

    XML To Array http://www.phpclasses.org/browse/package/2938.html

    At first make it as a php array and then do the search operation on array.

    Saturday, January 23, 2010 at 11:22 pm | Permalink
  2. rons_brain wrote:

    Use the XML parsing functions in PHP (http://us3.php.net/xml), load in your document, then use XPath expressions to pull back node sets mathing the search criteria.

    A better alternative is to import the XML data into a database. The schema looks fairly normalized, so this shouldn’t be difficult, and will provide much better performance compared to loading an XML file every time the user wants to do a search. Also, the XML files may get very large, which will really degrade performance down the road (not a scalable solution).

    Saturday, January 23, 2010 at 11:22 pm | Permalink
  3. backlinks wrote:

    Excellent backlinks links service – create The best search engine rankings and amazing site traffic with our powerful one way links packages. Best & valuable one way links solution of all time! backlinksGod.com – effective search engine optimization – any backlinks pointing – digital marketing – search engine marketing techniques – online communities

    Friday, November 11, 2011 at 4:37 am | Permalink
  4. Heya, I want to ask you something. Is this site a wordpress weblog? I will be thinking about transferring my blog site from Blogger to wordpress, you think that is doable? Additionally did you produce this unique theme by yourself some how? Thank you for your assistance!

    Wednesday, December 14, 2011 at 5:28 am | Permalink

Post a Comment

Your email is never published nor shared.