Re: IPN error
| From: | Stephen Lake | Date: | Sat, 29 Apr 2006 19:10:07 +0000 |
| Subject: | Re: IPN error | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-235106@lists.php.net to get a copy of this message | ||
Use cURL I found it much easier then using fsockopen
http://ca.php.net/cURL
""Richard Lynch"" <ceo@l-i-e.com> wrote in message
news:53198.67.184.121.112.1146304064.squirrel@www.l-i-e.com...
> On Sat, April 29, 2006 3:53 am, suresh kumar wrote:
>> <input type="hidden" name="item_name"
>> value="Subscribe to Additional User Account Yearly">
>
>> my page code to process paypal
>> ------------------------------
>> <?
>>
>> // read the post from PayPal system and add 'cmd'
>> $req = 'cmd=_notify-validate';
>>
>> foreach ($_POST as $key => $value) {
>> $value = urlencode(stripslashes($value));
>> $req .= "&$key=$value";
>
> echo "$key => $value<br />\n";
>
>> }
>>
>> $item_name = $_POST['item_name'];
>
> $item_name = isset($_POST['item_name']) ? $_POST['item_name'] :
> '';
>
>
>> Undefined index:item_name
>
> The $_POST data is not filled in, either because this is your FIRST
> visit to the page, or because something is not doing a POST request
> the way you think it should be.
>
> --
> Like Music?
> http://l-i-e.com/artists.htm