Created
April 15, 2010 05:39
-
-
Save code/366717 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" | |
"http://www.w3.org/TR/html4/strict.dtd"> | |
<html> | |
<head> | |
<meta http-equiv="Content-type" content="text/html; charset=utf-8"> | |
<title>index</title> | |
<link rel="stylesheet" href="style.css" type="text/css" media="screen" /> | |
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js"></script> | |
<script type="text/javascript" src="mustache.js"></script> | |
<script type="text/javascript" src="app.js"></script> | |
<script src="http://platform.twitter.com/anywhere.js?id=napdReg8vmaMotIRoyrg&v=chirp_preview"></script> | |
<script type="text/javascript"> | |
var tweet = "\ | |
<li>\ | |
<img class='profile-image' src='{{image_url}}' />\ | |
<p class='text'>{{screenName}} {{{text}}}</p>\ | |
<div class='clear'></div>\ | |
</li>"; | |
twttr.anywhere.config({ | |
assetHost: 'twitter-anywhere.s3.amazonaws.com' | |
}); | |
twttr.anywhere(function(T) { | |
T.User.current().homeTimeline().each(function(status) { | |
$("#timeline").append(Mustache.to_html(tweet, { | |
image_url: status.user.profileImageUrl, | |
screenName: status.user.screenName, | |
text: ify.clean(status.text) | |
})); | |
}); | |
T.User.current().friends().each(function(friend) { | |
$("#following").append("<img src="+ friend.profileImageUrl +" />"); | |
}); | |
}); | |
</script> | |
</head> | |
<body> | |
<div id="login"></div> | |
<ul id="timeline"></ul> | |
<div id="following"></div> | |
<div class="clear"></div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment