PHP传递变量以包含& Paypal IPN

时间:2013-11-11 02:44:10

标签: php paypal

客户在网站上购买后,Paypal会加载“notify_url”页面,其中我运行代码以向我的数据库添加信息。

所以在我的“notify_url”文件“file1.php”中,有这样的东西($ _POST ['a'] = 77):

$a = $_POST['a'];
$_POST['b'] = 88;
$_SESSION['test'] = 'test'; 
$action = 'buy';

include('file2.php');

...并在file2.php中:

echo $a; // result: ""
echo $action; // result: ""
echo $_SESSION['test']; // result: ""
echo $_POST['b']; // result: ""
echo $_POST['a']; result: "77"

为什么我的变量不在include中,但是POST呢?

0 个答案:

没有答案