My recommendations: If you just have a member id or screen name and want only the current profile image, use GET /users/profile_image to get the current URL as the return, then cache that value and use it as your image src.
If you are interested in more information about the user than just the profile photo, and you're starting with a member id or screen name, use bulk user lookup: GET users/lookup or GET users/show for the user in question. If you are simply rendering tweets and want to render an avatar next to the tweet, just use the profile image that's embedded in the user object for the tweet you're rendering. It's "right" more often than not. It comes down to context: what data you're starting with and what you're wanting to do with it. Taylor On Mon, Oct 11, 2010 at 3:57 PM, gabrielu <[email protected]> wrote: > So what's the right way to get user profile image? > > On Sep 30, 10:30 am, Tom van der Woerdt <[email protected]> wrote: > > Every image you load using this method counts as 1 API request. So, yes, > > that's bad. > > > > Tom > > > > On 9/30/10 11:48 AM, Jayawi Perera wrote: > > > > > > > > > > > > > > > > > Hi all, > > > > > I have a page in which there is a listing of past tweets. In this > > > page, I want to display the author's profile image next to the tweet. > > > I've come across the following: > > >http://dev.twitter.com/doc/get/users/profile_image/:screen_name > > > > > My question is, is it wrong to use this as the src within an img tag? > > > I raise the above question because of the following mentioned on that > > > page: > > > "This method should only be used by application developers to lookup > > > or check the profile image URL for a user. This method must not be > > > used as the image source URL presented to users of your application." > > > > > Thank you for your help. > > > > > Cheers, > > > Jayawi~ > > -- > Twitter developer documentation and resources: http://dev.twitter.com/doc > API updates via Twitter: http://twitter.com/twitterapi > Issues/Enhancements Tracker: > http://code.google.com/p/twitter-api/issues/list > Change your membership to this group: > http://groups.google.com/group/twitter-development-talk > -- Twitter developer documentation and resources: http://dev.twitter.com/doc API updates via Twitter: http://twitter.com/twitterapi Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list Change your membership to this group: http://groups.google.com/group/twitter-development-talk
