[support] Forms hate me
Ms. Nancy Wichmann
nan_wich at bellsouth.net
Thu Jan 3 15:31:42 UTC 2013
I have a form that I need to format (theme) as a table. The D6 version of the module works just fine. The D7 version is being rather obstinate.
Since I have a dsm() in the theme function, I know it is firing. However, the variables array passed to the theme has an empty array in it. Anyone see what I'm doing wrong?
function log_cleanup_theme() {
return array(
'log_cleanup_settings' => array(
'variables' => array('form' => array()),
'render element' => 'form',
),
);
}
function theme_log_cleanup_settings(&$variables) {
$form = $variables['form'];
dsm(print_r($variables, true));
$output = '';
$table = array();
$table['rows'] = array();
$table['header'] = array(
t('Message Type'),
t('Interval'),
);
// Spin through the intervals elements.
foreach (element_children($form['intervals']) as $key) {
Nancy
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/support/attachments/20130103/df6ee45f/attachment.html
More information about the support
mailing list