//獲得本地真實IP
functionget_onlineip() {
? ? ? ? $mip=file_get_contents("http://1212.ip138.com/ic.asp")
? ? ? ? if($mip){
? ? ? ? ? ? ? $sip=array();
? ? ? ? ? ? ? preg_match_all("/(?:\[)(.*)(?:\])/i",$mip,$sip);
? ? ? ? ? ? ? return ? ?$sip[1][0];
? ? ? }else{
? ? ? ? ? ? ? return ?"獲取本地IP失敗!";
}