Welcome to WebmasterWorld Guest from 126.96.36.199
Forum Moderators: httpwebwitch
I am in the process of creating an online store, all of my products & product information is already stored in a huge XML file with over 500 products. I have been researching the best way to categorize and display the products in an html page.
To be more precise I need to have navigation links to groups of products, for example if a customer clicks "Alltell Wireless" it will only show the products with the tag
Also I need to have individual pages for each of the 500 products.
here is an expert from the XML feed I will be using, note that this XML feed is being updated daily with new products.
<ManufacturerCode>Pearl 8130 White</ManufacturerCode>
<EquipmentName>BlackBerry Pearl 8130 White</EquipmentName>
The BlackBerry Pearl 8130 - a super-slim, ultra-light smartphone - is now available for Alltel customers in a crisp white shell. Like all BlackBerry devices, the BlackBerry Pearl 8130 provides a top notch on-the-go email solution for mobile professionals. But the BlackBerry Pearl 8130 also includes a good camera, a built-in music player, and broadband download speed for Web browsing. Best of all, this BlackBerry weighs in at a scant 3.2 ounces and is razor-thin - the smallest of its class.
<PriceAfterRebate>You make $100.00</PriceAfterRebate>
<RebateDescription>0.00 Mail-in<br>100.00 Mail-in</RebateDescription>
My question is what scripting language would be best for this task?
-PHP using DOM & SimpleXML I am most experienced and comfortable with PHP but is this task to large and complicated for PHP to handle?
-XSLT do I have to load up the entire XML file in order to display only parts of it using XSLT? if so this would not be realistic because of loading time.
-ASP I am not at all familiar with ASP but if it's the best choice I will learn
I am willing to study and learn a new language if required, I am most experienced in PHP.
Can some of the true experts please give me some guidance on how to implement this XML data feed into my website? thanks.
question 2: yes, XSLT would need to load the entire XML file. If your XML is huge, you're right that's not a great solution.
ASP is really no different than PHP. XSLT transformation is a little faster in ASP C#.NET, only if the stylesheet is compiled... but for selecting nodes with XPATH they're pretty much equivalent. Since you're more comfortable with PHP, that sounds like the best path for you.
You might want to consider using a relational database rather than an XML file. If you're receiving the data as XML, you can write a script that parses it and updates your database. It's a bit more work, but I'll guarantee SQL will find products faster than a complex XPATH expression.
Welcome to WebmasterWorld!