Full ELMS Learning Network documentation
function theme_entityreference_prepopulate_providers_table
×
Error message
User warning: The following module is missing from the file system: theme/theme. For information about how to fix this, see the documentation page. in _drupal_trigger_error_with_delayed_logging() (line 1156 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).cis7 EntityReferencePrepopulateInstanceBehavior.class.php | theme_entityreference_prepopulate_providers_table($variables) |
cle7 EntityReferencePrepopulateInstanceBehavior.class.php | theme_entityreference_prepopulate_providers_table($variables) |
elmsmedia7 EntityReferencePrepopulateInstanceBehavior.class.php | theme_entityreference_prepopulate_providers_table($variables) |
icor7 EntityReferencePrepopulateInstanceBehavior.class.php | theme_entityreference_prepopulate_providers_table($variables) |
meedjum_blog7 EntityReferencePrepopulateInstanceBehavior.class.php | theme_entityreference_prepopulate_providers_table($variables) |
mooc7 EntityReferencePrepopulateInstanceBehavior.class.php | theme_entityreference_prepopulate_providers_table($variables) |
Theme the providers table.
Related topics
2 string references to the theme hook from theme_entityreference_prepopulate_providers_table()
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.
- EntityReferencePrepopulateInstanceBehavior::settingsForm in sites/
all/ modules/ ulmus/ entityreference_prepopulate/ plugins/ behavior/ EntityReferencePrepopulateInstanceBehavior.class.php - Generate a settings form for this handler.
- entityreference_prepopulate_theme in sites/
all/ modules/ ulmus/ entityreference_prepopulate/ entityreference_prepopulate.module - Implements hook_theme().
File
- sites/
all/ modules/ ulmus/ entityreference_prepopulate/ plugins/ behavior/ EntityReferencePrepopulateInstanceBehavior.class.php, line 126
Code
function theme_entityreference_prepopulate_providers_table($variables) {
$form = $variables['form'];
$provider_names = element_children($form['enabled']);
foreach ($provider_names as $provider_name) {
$row = array(
'data' => array(
drupal_render($form['title'][$provider_name]),
drupal_render($form['enabled'][$provider_name]),
drupal_render($form['weight'][$provider_name]),
),
'class' => array('draggable'),
);
$rows[] = $row;
}
$header = array(
array('data' => t('Provider')),
array('data' => t('Enabled')),
array('data' => t('Weight')),
);
$table_variables = array(
'header' => $header,
'rows' => $rows,
'attributes' => array('id' => 'table-providers'),
);
$output = theme('table', $table_variables);
drupal_add_tabledrag('table-providers', 'order', 'sibling', 'provider-weight');
return $output;
}