SitePoint Sponsor |
|
User Tag List
Results 1 to 3 of 3
Thread: posting values to a URL
-
May 19, 2009, 15:05 #1
- Join Date
- Oct 2005
- Location
- Cape town, South Africa
- Posts
- 294
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
posting values to a URL
hi,
I am working on integrating a credit payment service from setcom. on completion of transaction setcom sends bunch of post variables that my script has to send back to setcom to get the details of the transaction as an xml file.
I am using the pecl_http extension(http_post_fields) for posting these variables but i have this reponse header info with the xml file that i can't get rid of. And the php doc isnt explicit enough on the use of this function:
Code:HTTP/1.1 200 OK Connection: close Date: Tue, 19 May 2009 21:56:02 GMT Content-Type: text/html; charset=UTF-8 Server: Microsoft-IIS/6.0 P3P: CP="IDC DSP CURa ADMa DEVa IVAa IVDa OUR DELa NOR LEG UNI PUR NAV INT DEM" X-Powered-By: ASP.NET Set-Cookie: CFID=142013;expires=Thu, 12-May-2039 21:56:02 GMT;path=/ Set-Cookie: CFTOKEN=99801499;expires=Thu, 12-May-2039 21:56:02 GMT;path=/ <?xml version='1.0' encoding='UTF-8'?><order_synchro><outcome><status>Complete</status>
How can i set the http_post_field function not to return response headers?
Help needed thanks in advance!
-
May 20, 2009, 00:31 #2
- Join Date
- Apr 2008
- Location
- North-East, UK.
- Posts
- 6,111
- Mentioned
- 3 Post(s)
- Tagged
- 0 Thread(s)
Try taking a look at cURL to post the values back, unless you have some affinity with using the PECL extension.
How are you receiving the data posted by the service?@AnthonySterling: I'm a PHP developer, a consultant for oopnorth.com and the organiser of @phpne, a PHP User Group covering the North-East of England.
-
May 20, 2009, 02:00 #3
- Join Date
- Oct 2005
- Location
- Cape town, South Africa
- Posts
- 294
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Thanks mate i used the http_parse_message to return a string of arrays on the response and it works perfectly.
Thanks
http://www.php.net/manual/en/functio...se-message.php
Bookmarks