【发布时间】:2016-12-03 04:21:49
【问题描述】:
**我需要在 url 上使用这个文件 php Variables post server **
http://example.com/addData.php (the other server)
-------------------------------------
$a_player1 = $_POST['a_player1'] = 1;
$a_player2 = $_POST['a_player2'] = 3;
htto://srore.com/getdata.php
-------------------------------------
include("http://example.com/addData.php");
echo $a_player1;
echo $a_player2;
错误???
Notice: Undefined variable: a_player1
Notice: Undefined variable: a_player2
php.ini 设置然后allow_url_include 开启
【问题讨论】:
-
如果两个文件在同一个文件夹中,不需要使用""http://...../test/",直接使用include("addData.php");
标签: php variables scope server include