|
|
@ -1,6 +1,7 @@
|
|
|
|
<?php
|
|
|
|
<?php
|
|
|
|
|
|
|
|
getIpInfo('120.32.100.138');
|
|
|
|
|
|
|
|
|
|
|
|
function getIpInfo() {
|
|
|
|
function getIpInfo($ip) {
|
|
|
|
// 云市场分配的密钥Id
|
|
|
|
// 云市场分配的密钥Id
|
|
|
|
$secretId = 'AKID5tH3om0m0dPG4KMBLFLp03E4zrOF0a1qTCXh';
|
|
|
|
$secretId = 'AKID5tH3om0m0dPG4KMBLFLp03E4zrOF0a1qTCXh';
|
|
|
|
// 云市场分配的密钥Key
|
|
|
|
// 云市场分配的密钥Key
|
|
|
@ -28,7 +29,7 @@ function getIpInfo() {
|
|
|
|
);
|
|
|
|
);
|
|
|
|
// body参数(POST方法下)
|
|
|
|
// body参数(POST方法下)
|
|
|
|
$bodyParams = array (
|
|
|
|
$bodyParams = array (
|
|
|
|
'ip' => '',
|
|
|
|
'ip' => $ip,
|
|
|
|
);
|
|
|
|
);
|
|
|
|
// url参数拼接
|
|
|
|
// url参数拼接
|
|
|
|
$url = 'https://service-hnhpr5tw-1305308687.gz.apigw.tencentcs.com/release/ip/query';
|
|
|
|
$url = 'https://service-hnhpr5tw-1305308687.gz.apigw.tencentcs.com/release/ip/query';
|
|
|
|