[development] Question on #theme attribute in D6 FAPI
Syscrusher
syscrusher at 4th.com
Wed Jul 9 23:32:34 UTC 2008
Good evening!
I have a form that works fine in Drupal 5 and uses the #theme attribute
to invoke a user-defined function. I'm trying to update the module to
Drupal 6, and am getting no errors, but the #theme function is no longer
being invoked (I placed trace statements there, and am using
devel.module for diagnostic printing using dprint_r()).
I checked the upgrade-your-module documentation (which is excellent,
btw), but there's no mention of a change to how #theme works. Have I
overlooked a change that's documented elsewhere?
Here are the code snippets. In the code that generates the $form array,
I have this:
$form['links_related']['#theme'] = 'links_related_form';
and the theme function is defined thusly:
function theme_links_related_form($form)
I have a trace print() statement right inside that function as the first
line, so I know the function isn't being called.
By the way, the form itself generates and executes correctly, with all
fields working. The only problem is that the theming isn't being called,
so I'm getting plain vanilla output rather than the table that is
supposed to neatly align the columns (my theme function calls Drupal's
core theme('table', ....) function to do this).
Again, this worked in D5, so I'm looking for what needs to change for
D6.
Thanks for any suggestions.
Scott
--
Syscrusher <syscrusher at 4th.com>
More information about the development
mailing list