使用thinkphp中擴展庫獲取ip:
import("ORG.Net.IpLocation");
$ipnew = new IpLocation();$location = $ipnew->getlocation('www.thinkphp.cn');
dump($location);
僅僅獲取Ip可以用:$ip = get_client_ip();
使用thinkphp中擴展庫獲取ip:
import("ORG.Net.IpLocation");
$ipnew = new IpLocation();dump($location);
僅僅獲取Ip可以用:$ip = get_client_ip();
<?php //mysql 5.7及以上版本,需要加入limit限制,先算出總的記錄條數 $countz = Db::table("order_detail")->where($odmap)->