引用下面的js:

<script src="http://pv.sohu.com/cityjson?ie=utf-8"></script>

直接获取IP和城市名:

alert(returnCitySN['cip'] + returnCitySN['cname']);

 

  

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-26
  • 2022-12-23
  • 2021-12-22
  • 2022-12-23
  • 2022-01-12
猜你喜欢
  • 2021-07-11
  • 2021-07-15
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案