Dojo连接到Flickr数据库范例

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>&#26080;&#26631;&#39064;&#25991;&#26723;</title>
<link rel="stylesheet" type="text/css" href="../js/dijit/themes/tundra/tundra.css" />
<link rel="stylesheet" type="text/css" href="../js/dojo/resources/dojo.css" />
<script type="text/javascript" src="../js/dojo/dojo.js" djConfig="parseOnLoad: true">
</script>
<script type="text/javascript">
	dojo.require("dojo.string");
	dojo.require("dojo.io.script");
	dojo.addOnLoad(
		function(){
		dojo.io.script.get({
			callbackParamName : "jsoncallback",
			url: "http://www.flickr.com/services/feeds/photos_public.gne",
			content: {format: "json"},
			load: function(response, ioArgs) {
				console.log(response);
				return response;
			},
			error: function(response, ioArgs) {
				console.log("error");
				console.log(response);
				return response;
			}
		});
	});
</script>
</head>

<body>
</body>
</html>

你可能感兴趣的:(html,json,XHTML,dojo)