public static function query($query_date, $from_station, $to_station)
{
$url = 'https://kyfw.12306.cn/otn/lcxxcx/query?';
$param = array('purpose_codes' => 'ADULT', 'queryDate' => $query_date, 'from_station' => $from_station, 'to_station' => $to_station);
$url .= http_build_query($param);
do {
$restul = Helper_Http::get($url);
$rt = json_decode($restul, true);
if (isset($rt['status']) && $rt['status']) {
self::do_query($rt['data']['datas']);
} else {
if (isset($rt['messages'])) {
var_dump($rt['messages']);
} else {
var_dump($restul);
}
}
} while (true);
}