function get_latest_shout in Heartbeat 6.3
Same name and namespace in other branches
- 6.4 modules/shouts/shouts.module \get_latest_shout()
Get the latest shout of a user.
Parameters
$uid user_id of shout to load:
1 call to get_latest_shout()
- shouts_user in modules/
shouts/ shouts.module - Implementation of hook_user().
File
- modules/
shouts/ shouts.module, line 211 - Gives the possibility to the user to shout a message.
Code
function get_latest_shout($uid) {
$shout = db_fetch_object(db_query_range('SELECT message, cleared, time FROM {shouts} WHERE uid = %d ORDER BY time DESC', $uid, 0, 1));
return $shout;
}