User objects quick guide

From Dreamwidth Notes
Jump to: navigation, search

The user object is one of the main components of the LJ code. Here is a quick tour of some commonly used functions.

Get an account

Most useful function for this:


This will get the user object for a user OR for an OpenID identity URL.

Find out what kind of account it is


Managing WTF relationships

Managing watch/trust/friend relationships: see WTF Backend.

Community functions

Getting members:


Display the account

This gives the HTML to render the username complete with the little profile icon: