[support] How to send a XML to drupal menu callback

Gordon Heydon gordon at heydon.com.au
Wed Jun 30 07:56:27 UTC 2010


Hi

The XML will not appear in the post. You need to read the raw stream

See http://www.codediesel.com/php/reading-raw-post-data-in-php/

Gordon

Sent from my iPad

On 30/06/2010, at 5:41 PM, Michel Morelli <michel at ziobuddalabs.it> wrote:

> Metzler, David ha scritto:
>> Ummm... Looks like you're mixing your metaphores.
>>
>> To pass variables using CGI, they must be properly encoded key value
>> pairs.  Example:
>>
>> $data = array('xml'=>$xml);
>> $data_string = drupal_query_string_encode($data);
>> drupal_http_request("http://mysite.it/foo",$header,"POST",$xml,3);
>>
>>
> Hi, my code works perfectly if i call a web application created by 3rd
> farm.
> In Drupal I have the problem that POST is empty.
>
> M.
>
>
> --
> Michel 'ZioBudda' Morelli                       michel at ziobuddalabs.it
> Sviluppo applicazioni CMS DRUPAL e web dinamiche (LAMP+Ajax)
> Telefono: 0200619074
> Telefono Cell: +39-3939890025 --  Fax: +39-0291390660
>
> http://www.ziobudda.net                         ICQ: 58351764
> http://www.ziobuddalabs.it                      Skype: zio_budda
> http://www.ziodrupal.net       			MSN: michel at ziobuddalabs.it
> 						JABBER: michel at ziobuddalabs.it
>
> --
> [ Drupal support list | http://lists.drupal.org/ ]


More information about the support mailing list