Re: [PHP] Changing perl to PHP

2001-09-12 Thread Jason Brooke
> $fp = fsockopen("www.paypal.com", 443, $errono, $errstr, 30); > if (!$fp) { > echo "$errstr ($errno)\n"; > } else { > fputs ($fp, "GET https://www.paypal.com/cgi-bin/webscr > HTTP/1.1\015\012"); > fputs ($fp, "HOST www.paypal.com\015\012"); > fputs ($fp, "Content-type: applicati

Re: [PHP] Changing perl to PHP

2001-09-11 Thread ReDucTor
fgets ($fp,128); } fclose ($fp); } ?> - Original Message - From: "Richard Kurth" <[EMAIL PROTECTED]> To: "php" <[EMAIL PROTECTED]> Sent: Wednesday, September 12, 2001 4:01 PM Subject: [PHP] Changing perl to PHP > Could somebody tell me how to co

Re: [PHP] Changing perl to PHP

2001-09-11 Thread Jason Brooke
> # read the post from PayPal system and add 'cmd' > read (STDIN, $query, $ENV{'CONTENT_LENGTH'}); > $query .= '&cmd=_notify-validate'; > > # post back to PayPal system to validate > use LWP::UserAgent; > $ua = new LWP::UserAgent; > $req = new HTTP::Request 'POST','https://www.paypal.com/cgi-bin/w

[PHP] Changing perl to PHP

2001-09-11 Thread Richard Kurth
Could somebody tell me how to convert this little bet of code to PHP. The rest of the code for this was easy to do but I dont know what to do with this. Can I call LWP from php and if yes how? # read the post from PayPal system and add 'cmd' read (STDIN, $query, $ENV{'CONTENT_LENGTH'}); $query .=