為什么獲取不出來IP
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>11111</title>
<script type="text/javascript" src="https://apis.juhe.cn/ip/Example/query.php?action=current"></script><script type="text/javascript">
document.write('ip地址:' + returnCitySN["ip"]);
?<script type="text/javascript">
?
</script>
</head>
<body>
</body>
2020-03-19
說實(shí)話看不懂你在弄什么,看看我這個(gè)吧
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<script type="text/javascript">
</script>
</head>
<body>
<form action="https://apis.juhe.cn/ip/Example/query.php?action=current" method="post">
<input type="submit" value="點(diǎn)擊獲取ip"/>
</form>
</body>
</html>
2020-02-26
<script > </script> 嵌套過多,而且沒有寫成function無法相互調(diào)用。 建議去除只留一個(gè)試試。