Link to home
Start Free TrialLog in
Avatar of cataleptic_state
cataleptic_stateFlag for United Kingdom of Great Britain and Northern Ireland

asked on

PHP Toolkit for PayPal v0.51 ipn

Hi I am using a script available online called PHP Toolkit for PayPal v0.51

I have used it on a test site i am making, but I need to get something working that I have realsed I need.

It has a ipn folder that has a ipn_success.php file which says:

{see attached code}

What I need it to do is change the database table for that order to say "Yes" if the payment has gone through.

I assume its done there, as the comment says:
//log successful transaction to file or database

I need to know how to get this working, and how is the order sent back to the site, with a order id? or something else?

I really would like to get this working.

Thanks for any help you can provide.
I wish I could give you 1000 points to get this working as soon as possible

//include file - not accessible directly
if(isset($paypal['business']))
{
//log successful transaction to file or database

}
else
{
	die('This page is not directly accessible');
}
?>

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of cataleptic_state
cataleptic_state
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I'd suggest that you should hire a PayPal developer to help with this.  It is not a single issue or a simple issue, and there are penalties for making mistakes with money - some of these involve handcuffs.  Better safe than sorry.

I can help with one critical part of the process.  When you are trying to debug any asynchronous script like the PayPal IPN, you have no browser output and that makes it difficult to visualize your data.  What I like to do is capture the output buffer and mail it to myself.  See the code example for how this is done.

best regards, ~Ray


<?php // RAY_ob_start_example.php
error_reporting(E_ALL);
ob_start();

// CREATE SOME DATA
echo "Hello World";

// CREATE AN ERROR NOTICE
$x = $y;

// GRAB THE BROWSER OUTPUT BUFFER
$buffer = ob_get_clean();
mail('You@Your.org', 'OUTPUT BUFFER', $buffer);

Open in new window

So what was the solution?
Avatar of cataleptic_state

ASKER

I had to hire someone to make it work, its still not working 100%