theme_domain_prefix_configure_form

Versions
domain
theme_domain_prefix_configure_form($form)

FormsAPI theming for domain_prefix_configure_form.

Code

domain_prefix/domain_prefix.admin.inc, line 176

<?php
function theme_domain_prefix_configure_form($form) {
  $output = t('<p>These settings control advanced functions.  Please read the documentation carefully.</p>');
  $header = array(t('Table'), t('Source'), t('Ignore'), t('Create'), t('Copy'));
  if (!empty($form['prefix_theme']['#value'])) {
    $header[] = t('Update');
    $header[] = t('Drop');
    unset($form['prefix_theme']);
  }
  $output = drupal_render($form['domain']);
  foreach (element_children($form['domain_prefix']) as $key) {
    if ($form['domain_prefix'][$key]['#description']) {
      $rows[] = array('<b>'. $form['domain_prefix'][$key]['#description'] .'</b>', array('', 'colspan' => count($header)));
    }
    $row = array();
    $row[] = ' - '. $form['domain_prefix'][$key]['#title'];
    // Insert the source selection element.
    $row[] = drupal_render($form['domain_source']['_source_'. $key]);
    foreach (element_children($form['domain_prefix'][$key]) as $option) {
      $row[] = drupal_render($form['domain_prefix'][$key][$option]);
    }
    // Throw the rest away, since we already rendered what we want from it.
    $render = drupal_render($form['domain_prefix'][$key]);
    $rows[] = $row;
  }
  $output .= theme('table', $header, $rows);
  $output .= drupal_render($form);
  return $output;
}
?>

Contact

  • agentrickard [at] gmail [dot] com

Donations

My Amazon.com Wish List