function theme_pm_block_user_actions

1 pm_block_user.module theme_pm_block_user_actions($form)
7-1 pm_block_user.module theme_pm_block_user_actions($form)
7-2 pm_block_user.module theme_pm_block_user_actions($form)
6-2 theme_pm_block_user_actions($form)

Theme the user actions form.

Related topics

5 string references to the theme hook from theme_pm_block_user_actions()

Note: this list is generated by looking for the string for this theme hook, so it may include some references that are not actually using this theme hook.

pm_block_user_query_privatemsg_autocomplete_alter in pm_block_user/pm_block_user.module
Implements hook_query_TAG_alter().
pm_block_user_settings in pm_block_user/
Menu callback for blocked user settings.
pm_block_user_settings_submit in pm_block_user/
Submit handler for admin form.
pm_block_user_theme in pm_block_user/pm_block_user.module
Implements hook_theme().
_pm_block_user_rule_exists in pm_block_user/pm_block_user.module
Checks whether a rule exists for a given author, recipient and action.


pm_block_user/pm_block_user.module, line 117
Allows users to block other users from sending them any messages


function theme_pm_block_user_actions($form) {
  // @todo: Something is wrong, remove this hack.
  $form = $form['form'];

  $rows = array();
  $headers = array(
    t('If the author has the role'),
    t('And the recipient has the role'),
  $form_data = element_children($form);

  foreach ($form_data as $key) {
    // Build the table row.
    $row = array('data' => array(
        array('data' => drupal_render($form[$key]['author'])),
        array('data' => drupal_render($form[$key]['recipient'])),
        array('data' => drupal_render($form[$key]['action'])),
        array('data' => drupal_render($form[$key]['enabled'])),
        array('data' => drupal_render($form[$key]['remove'])),

    // Add additional attributes to the row, such as a class for this row.
    if (isset($form[$key]['#attributes'])) {
      $row = array_merge($row, $form[$key]['#attributes']);
    $rows[] = $row;

  // If there are no rows, output some instructions for the user.
  if (empty($form_data)) {
    $rows[] = array(array(
        'data' => t("No rules have been added. All users may block private messages from each other. To limit which users may be blocked, click 'Add new rule'."),
        'colspan' => '5',

  $output = theme('table', array('header' => $headers, 'rows' => $rows));
  $output .= drupal_render_children($form);

  return $output;