function viewreference_elements in View reference 6.2
Same name and namespace in other branches
- 6.3 viewreference.module \viewreference_elements()
- 6 viewreference.module \viewreference_elements()
Implementation of FAPI hook_elements().
Any FAPI callbacks needed for individual widgets can be declared here, and the element will be passed to those callbacks for processing.
Drupal will automatically theme the element using a theme with the same name as the hook_elements key.
Autocomplete_path is not used by text_widget but other widgets can use it (see viewreference and userreference).
File
- ./
viewreference.module, line 347 - Defines a field type for referencing a view from a node.
Code
function viewreference_elements() {
return array(
'viewreference_select' => array(
'#input' => TRUE,
'#columns' => array(
'uid',
),
'#delta' => 0,
'#process' => array(
'viewreference_select_process',
),
),
'viewreference_autocomplete' => array(
'#input' => TRUE,
'#columns' => array(
'name',
),
'#delta' => 0,
'#process' => array(
'viewreference_autocomplete_process',
),
'#autocomplete_path' => FALSE,
),
);
}