1
使用:Laravel stevebauman /位置返回錯誤的數據
- Larvel 4.2
- 定位包從https://github.com/stevebauman/location
我本地開發的應用程序與上面的細節,但使用包中的數據時,我回來是不正確的。
我已經通過兩種方式測試了這個,首先是自動ip檢測例如:Location :: get();和第二個通過手動輸入我的IP 例如:Location :: get('192.168.1.1');
每次我得到這個相同的數據回:
object(Stevebauman\Location\Objects\Location)[141]
public 'countryName' => string 'United States' (length=13)
public 'countryCode' => string 'US' (length=2)
public 'regionCode' => string 'CA' (length=2)
public 'regionName' => string 'California' (length=10)
public 'cityName' => string 'Mountain View' (length=13)
public 'zipCode' => string '' (length=0)
public 'isoCode' => string '' (length=0)
public 'postalCode' => string '94043' (length=5)
public 'latitude' => float 37.4192
public 'longitude' => float -122.0574
public 'metroCode' => string '' (length=0)
public 'areaCode' => string '' (length=0)
public 'isp' => string 'Google Inc.' (length=11)
public 'ip' => string '66.102.0.0' (length=10)
public 'driver' => string 'Stevebauman\Location\Drivers\Telize' (length=35)
public 'error' => boolean false
任何想法?
銘記我從**英國**而不是「美國」 – 2015-02-09 12:25:20
嗨,我是位置包的開發者。我很高興你已經解決了你的問題!如果您遇到更多問題,請在git存儲庫上創建問題:https://github.com/stevebauman/location/issues – 2015-05-06 01:21:36