-- river_jetties <[EMAIL PROTECTED]> wrote
(on Wednesday, 02 April 2008, 06:10 PM -0700):
> I am writing a ZF application to process some xml sent to me by a flash
> client.
> 
> Normally, I would this via:
> $xml_str=file_get_contents("php://input");
> to access the raw POST variables which would kickoff whatever
> processing and response I would need sent out. It doesn't look like
> there is an intuitive way to access this via ZF. How would someone
> suggest that I access the raw POST? 

If you're using the MVC, you can do this via the request object:

    $xml_str = $this->getRequest()->getRawBody();

(getRawBody() was added for 1.5.0)

> I thought maybe Zend_Feed would be helpful but it looks like if I'm
> outside RSS or Atom, they won't help much. I'll probably  just have a
> process xml funciton that uses simplexml to go through the request and
> XMLWriter to output information.

That's typically the way to process arbitrary XML in PHP anyways. :-)

-- 
Matthew Weier O'Phinney
PHP Developer            | [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/

Reply via email to