Html静态页面如何根据IP显示所在的城市名或图片?
asp后台生成的html静态页面。。。现在首页有张图片需要根据不同的城市显示对应的图片出来。。如何解决??
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www."> <html xmlns="http://www."> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> <script language="javascript" src="http://fw."></script> <script language="javascript"> window.onload = function() { var url = "http://bbs.bccn.net/images/default/logo.gif"; var city = IPData[3]; switch(city) { case "深圳市": document.getElementById("lele").src = url; } } </script> <title>乐乐</title> </head> <body> <img src="http://www.baidu.com/img/baidu_logo.gif" id="lele" /> </body> </html>