日期:2014-05-16 浏览次数:20690 次
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-
transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>
xxx
</title>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js">
</script>
<script type="text/javascript">
jQuery(document).ready(function() {
$.ajax({
type: "get",
async: false,
data: {
},
url: "http://www.geonames.org/postalCodeLookupJSON?postalcode=10504&country=US",
dataType: "jsonp",
jsonp: "callback",
success: function(json) {
for (var e in json.postalcodes[0]) {
document.write(e + "--->" + json.postalcodes[0][e]+"<br/>");
}