Skip to content

Instantly share code, notes, and snippets.

View litaonet's full-sized avatar

小六 litaonet

  • 西安,中国
View GitHub Profile
<?php
$fs = fopen('./cycle_hook.log', 'a');
$client_ip = $_SERVER['REMOTE_ADDR'];
fwrite($fs, 'Request on ['.date("Y-m-d H:i:s").'] from ['.$client_ip.']'.PHP_EOL);
$json = file_get_contents('php://input');
$data = json_decode($json, true);
/* 后端数据 */
var data = {
"10;20;30": {
price: 5,
count: 1
},
"10;20;31": {
price: 10,
count: 2
},