SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Addict Eric1776's Avatar
    Join Date
    May 2002
    Location
    Atlanta, GA
    Posts
    227
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Advantages of using XML with PHP?

    I've been hooked on php and have heard that XML with PHP can be very powerful. I understand how to write an XML document, but thats all so far.

    What advantages would I have if I were to use XML?

    My next project is an ecommerce website. Would XML be good to use for parts of it?

    Is there any good books out there for using XML with PHP?

    Thanks

  2. #2
    SitePoint Wizard gold trophysilver trophy
    Join Date
    Nov 2000
    Location
    Switzerland
    Posts
    2,479
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Think you have to ask yourself what XML really is.

    IMO XML is ultimately a techology for exchanging data between systems in a platform independent manner.

    For an e-commerce site, I'd investigage "web services" with either SOAP or using an approach like Amazons REST based XML service. The idea would be to make your sites content available for other sites to display, there by enabling sales to begin on other websites and effectively increasing your market.

  3. #3
    SitePoint Addict Eric1776's Avatar
    Join Date
    May 2002
    Location
    Atlanta, GA
    Posts
    227
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That would be a huge benefit in my case. One of my clients has many related sites where he wants seperate shopping carts for seperate goods, but they all complement each other.

    To be able to cross populate products would be a big benefit.

    I can think of a few other good uses for that also.

  4. #4
    SitePoint Wizard gold trophysilver trophy
    Join Date
    Nov 2000
    Location
    Switzerland
    Posts
    2,479
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    On the books front, Wrox's "Pro PHP XML" (which I have and like) and New Riders "PHP and XML" both have good reputations.

    Generally I'd say though for what you want to do, consider making your content available as both (X)HTML and XML (via a slight modified URL). Displaying the latter should be basically the same as the HTML but without any "user interface" (navigation etc.). Once you've got that far, investigate WSDL which basically should provide you a means to "index" your XML.


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
  •