Return DataTable from WCF service to PHP client

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Swys
    New Member
    • Mar 2009
    • 5

    Return DataTable from WCF service to PHP client

    Hi all!

    I am creating a WCF service (my first). I am going to have a variety of clients, one of which is a PHP client.

    Now, I've already established that I can return a normal string to the PHP client as wellas an array of strings. I also want to return a DataTable object in such a way that the PHP client will be able to understand the DataTable. Thus far, when a DataTable is returned to the PHP client, the result is one long continuous string with all the data that is in the DataTable.

    How can I return a DataTable from my service so that the PHP client will be able to understand it?
  • Swys
    New Member
    • Mar 2009
    • 5

    #2
    Or to put it better, I would like to enable the PHP client to receive any complex data type that the WCF service may return.

    Can anyone please help?

    Comment

    • Frinavale
      Recognized Expert Expert
      • Oct 2006
      • 9749

      #3
      Have you tried using XML Serialization on the DataTable?
      This should produce an XML file that you could parse in your PHP code.

      Comment

      Working...