« Return to Thread: xml parser

RE: xml parser

by Vasil Rangelov :: Rate this Message:

| View in Thread

I personally prefer DOM [1] and XMLReader [2], but SimpleXML [3] and "XML
Parser" [4] work too.

DOM and SimpleXML can be used for both reading and writing, whereas
XMLReader and "XML Parser" are only for reading (with XMLReader having its
writing companion - XMLWriter [5]).

I'm not sure I get your question about "write xml data to a server url"...
the same server your PHP file is running on, or a remote server?

If the former, DOM, SimpleXML and XMLWriter allow you to point a file path
(not a URL) to save the document to.

If the latter, you send it in the same way you'd send any text data - as a
raw body or get/post field of an HTTP request. It's up to the remote server
to handle processing the received data.

[1] http://php.net/DOM
[2] http://php.net/XMLReader
[3] http://php.net/SimpleXML
[4] http://php.net/XML
[5] http://php.net/XMLWriter


-----Original Message-----
From: Mumtaz kj [mailto:mumtaz.kjm@...]
Sent: Monday, March 26, 2012 8:20 PM
To: pear-dev@...
Subject: [PEAR-DEV] xml parser

Hi ,

could you please let me know what is a good method to do xml parsing  of a
string returned from a server,  using php.

as well as to write xml data to a server url,  using php.

i really appreciate your help. thankyou very much

Mumtaj


--
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

 « Return to Thread: xml parser