Skip to content

Instantly share code, notes, and snippets.

@lizheming
Created January 4, 2012 02:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lizheming/1558083 to your computer and use it in GitHub Desktop.
Save lizheming/1558083 to your computer and use it in GitHub Desktop.
jQ显示新浪微博消息
<html>
<head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
</head>
<body>
<div id="sina"></div>
<script type="text/javascript">
$(function() {
$.getJSON('https://api.weibo.com/2/statuses/user_timeline.json?source=2546437393&screen_name=mattdallas&callback=?', function(content){
var statuses = content.data.statuses;
$.each(statuses, function(i,item){
$(item.text).appenTo('#sina');
});
});
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment