cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

CURL for absolute dummies

From: Niels Peter Ludvigsen <nielz_p_at_hotmail.com>
Date: Tue, 12 Aug 2008 11:58:36 +0200

Hello,
 
I simply do NOT get how you receive/extract the information POSTED by CURL.
 
Could someone help with examples on this? It seems I am the only one not getting this, as I have not been able to find information on it.
 
All I keep getting of info is how easy it is, and you do this (for example):
extract($_POST);
$url = 'http://www.example.com/receiving_end.php'; $fields = array( 'xx1'=>urlencode($_POST['xx1']), 'xx2'=>urlencode($_POST['xx2']), 'xx3'=>urlencode($_POST['xx3']), 'xx4'=>urlencode($_POST['xx4']), 'xx5'=>urlencode($_POST['xx5']), 'xx6'=>urlencode($_POST['xx6']) ); foreach($fields as $key=>$value) { $fields_string .= $key.'='.$value.'&'; } rtrim($fields_string,'&');
curl_setopt($ch,CURLOPT_URL,$url); curl_setopt($ch,CURLOPT_POST,count($fields)); curl_setopt($ch,CURLOPT_POSTFIELDS,$fields_string); $result = curl_exec($ch);
curl_close($ch);
 
Okay fine I got this part, and YES CURL is activated.
 
What I need to know is what needs to be done at >>>receiving_end.php<<< How do I handle the incoming information? This is apparently where im a complete dummy :)
Really hope you can help with this, and come with some detailed explination on how that is handled.
_________________________________________________________________
Connect to the next generation of MSN Messenger 
http://imagine-msn.com/messenger/launch80/default.aspx?locale=en-us&source=wlmailtagline

_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2008-08-12