Issue #2031319 by jlindsey15, pplantinga, thedavidmeister, Kingdutch, Kiphaas7: Document that theme() should really be called via drupal_render().
parent
9f75c68768
commit
9143ca3000
|
@ -793,11 +793,17 @@ function drupal_find_base_themes($themes, $key, $used_keys = array()) {
|
||||||
/**
|
/**
|
||||||
* Generates themed output.
|
* Generates themed output.
|
||||||
*
|
*
|
||||||
* All requests for themed output must go through this function. It examines
|
* All requests for themed output must go through this function (however,
|
||||||
* the request and routes it to the appropriate
|
* calling the theme() function directly is strongly discouraged - see next
|
||||||
|
* paragraph). It examines the request and routes it to the appropriate
|
||||||
* @link themeable theme function or template @endlink, by checking the theme
|
* @link themeable theme function or template @endlink, by checking the theme
|
||||||
* registry.
|
* registry.
|
||||||
*
|
*
|
||||||
|
* Avoid calling this function directly. It is preferable to replace direct
|
||||||
|
* calls to the theme() function with calls to drupal_render() by passing a
|
||||||
|
* render array with a #theme key to drupal_render(), which in turn calls
|
||||||
|
* theme().
|
||||||
|
*
|
||||||
* @section sec_theme_hooks Theme Hooks
|
* @section sec_theme_hooks Theme Hooks
|
||||||
* Most commonly, the first argument to this function is the name of the theme
|
* Most commonly, the first argument to this function is the name of the theme
|
||||||
* hook. For instance, to theme a taxonomy term, the theme hook name is
|
* hook. For instance, to theme a taxonomy term, the theme hook name is
|
||||||
|
@ -897,6 +903,7 @@ function drupal_find_base_themes($themes, $key, $used_keys = array()) {
|
||||||
* An HTML string representing the themed output or FALSE if the passed $hook
|
* An HTML string representing the themed output or FALSE if the passed $hook
|
||||||
* is not implemented.
|
* is not implemented.
|
||||||
*
|
*
|
||||||
|
* @see drupal_render()
|
||||||
* @see themeable
|
* @see themeable
|
||||||
* @see hook_theme()
|
* @see hook_theme()
|
||||||
* @see template_preprocess()
|
* @see template_preprocess()
|
||||||
|
|
Loading…
Reference in New Issue