[development] finding the $form_id of a particular form / all
forms.
Robrecht Jacques
robrechtj+drupal at gmail.com
Sat Jul 1 11:10:23 UTC 2006
On 7/1/06, Augustin (a.k.a. Beginner) <drupal.beginner at wechange.org> wrote:
>
> hook_form_alter() allows us to change forms according to their form_id:
> http://api.drupal.org/api/HEAD/function/hook_form_alter
>
> Am I missing something easy, or the only way to figure out what is the
> form_id
> of a specific form is to pour over the code and figure out which module
> initialized the said form?
Or look into the HTML output. Each HTML form-element has an ID attribute.
Devel.module doesn't seem to help with that.
It could I suppose. Eg by implementing a hook_form_alter() that stores all
the ids Drupal requested to alter and then display that list at the bottom
of the page. Or maybe use hook_form_alter() to add a visible form-item
(which mentions the form_id) somewhere in the form.
But you're right, at the moment, devel.module has no such feature.
Use the source Luke :-)
Robrecht
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20060701/09b95036/attachment.htm
More information about the development
mailing list