Add Presence to Your Web Site

Let your visitors know when you’re online by connecting your site to Yahoo! Messenger.

The Web is great for asynchronous communication. That is, I can post something to my web site at 4:00 a.m., and you can read what I’ve written at any point after that. We don’t need to be sitting at our computers at the same time to share information. However, if both of us want to have a realtime text conversation—similar to a telephone coversation, but typed rather than spoken—the Web doesn’t work nearly as well, and that’s where instant messaging can help.

Yahoo! Instant Messenger is a program that lets you communicate with other people in real time. If you and a friend both have Yahoo! Instant Messenger and you’re both at your respective computers at the same time, you can send messages back and forth instantly. The program lets you set a status that lets others know whether you’re currently available. This status, or presence, is available only to people who have you on their Yahoo! Instant Messenger friends list and who have the program open. But with some simple HTML, you can make your presence known to anyone browsing your web site.

Yahoo! has opened a back door to the current online status of Yahoo! members, called the Online Presence Indicator. Thanks to a predictable image URL, you can display a graphic on your web site that tells people whether you’re available to chat. If one of your readers also has Yahoo! Instant Messenger, he’ll be able to click the ...

Get Yahoo! Hacks now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.