服务器api接收log

1
2
3
4
5
6
7
8
9
10
11
12
$input file_get_contents('php://input');
$myfile fopen("newfile.txt""w"or die("Unable to open file!");
 
$array = xmlToArray($input);
$EventKey $array['EventKey'];
 
$s explode('_'$EventKey);
$recom_id $s[1];
 
$user_openid $array['FromUserName'];
fwrite($myfile$input);
fclose($myfile);