drupal_set_content

  1. drupal
    1. 4.7
    2. 5
    3. 6 common.inc
Versions
4.7 drupal_set_content($region = null, $data = null)
5 – 6 drupal_set_content($region = NULL, $data = NULL)

Set content for a specified region.

Parameters

$region Page region the content is assigned to.

$data Content to be set.

▾ 2 functions call drupal_set_content()

drupal_get_content in includes/common.inc
Get assigned content.
theme_block_admin_display in modules/block.module
Theme main block administration form submission.

Code

includes/common.inc, line 36

<?php
function drupal_set_content($region = null, $data = null) {
  static $content = array();

  if (!is_null($region) && !is_null($data)) {
    $content[$region][] = $data;
  }
  return $content;
}
?>