You are here

private function user_activity::log_message in Heartbeat 6.2

Logs a heartbeat message

Parameters

string language optional :

2 calls to user_activity::log_message()
user_activity::save_locale in ./heartbeat.module
Save activity log with multilingual content and multilingual parts to pre-translate
user_activity::_save in ./heartbeat.module
Save activity log

File

./heartbeat.module, line 149
To fully understand this, you have to be familiar with the rules module. Lots of documentation can be found on http://drupal.org/node/298480 for an introduction and tutorial, but http://drupal.org/node/298486 is a lot of handy info for developers.

Class

user_activity
Class to handle user activity data

Code

private function log_message($args, $lang = '') {
  if ($lang == '') {
    global $language;
    $lang = $language->language;
  }

  // Log relational message to user activity
  db_query("INSERT INTO user_activity SET uid=%d, uid_target=%d, nid_target=%d, hid=%d,  language='%s', \n    message='%s', timestamp=%d, event='%s', variables='%s'", $this->m_uid, $this->m_uid_target, $this->m_nid_target, $this->m_hid, $lang, t($this->m_message, $args, $lang), $_SERVER['REQUEST_TIME'], $this->event, $this->m_variables_string);
}