I'm using the following portion of code in a program for IPN Validation with Paypal:
-----------------------
$query = "the information that paypal sends the server when a person purchases something";
use LWP::UserAgent;
$useragent = new LWP::UserAgent;
$request = new HTTP::Request 'POST','
$request->content_type('application/x-$request->content($query);
$results = $useragent->request($request);
-----------------------
It is for an IPN authorization script on a website i'm working on. My problem is that I should be getting a code back from the http post that I am doing, but instead I am getting this hash shown below:
HTTP::Response=HASH(0x8280e30)
I should be getting back the words VERIFIED or INVALID, but i'm getting this gibberish instead? Can anyone tell me what I am doing wrong in my script? Just so everyone knows, it is a redhat 7.2 server with PERL 5.6.1.
The script is posting back to Paypal with the proper information, but I can't seem to read the response that I need to validate the transaction with Paypal. If someone has a better snippet of code to do that same thing I am trying to do, it would be appreciated.
Thanks,
Panthaur
-----------------------
$query = "the information that paypal sends the server when a person purchases something";
use LWP::UserAgent;
$useragent = new LWP::UserAgent;
$request = new HTTP::Request 'POST','
$request->content_type('application/x-$request->content($query);
$results = $useragent->request($request);
-----------------------
It is for an IPN authorization script on a website i'm working on. My problem is that I should be getting a code back from the http post that I am doing, but instead I am getting this hash shown below:
HTTP::Response=HASH(0x8280e30)
I should be getting back the words VERIFIED or INVALID, but i'm getting this gibberish instead? Can anyone tell me what I am doing wrong in my script? Just so everyone knows, it is a redhat 7.2 server with PERL 5.6.1.
The script is posting back to Paypal with the proper information, but I can't seem to read the response that I need to validate the transaction with Paypal. If someone has a better snippet of code to do that same thing I am trying to do, it would be appreciated.
Thanks,
Panthaur