hook_page_alter

Events happening in the community are now at Drupal community events on www.drupal.org.
python1340's picture

Omega template.php vs. preprocess/process

From what I understand, the proper place to put code to alter a form is in hook_form_alter. So I created a function mytheme_alpha_form_alter() and put it in template.php. Everything works fine, however the comments in template.php suggest that I should keep that file "as clean as possible" and to use the preprocess and process subfolders instead. So in trying to do things the proper alpha/omega way, I created a file preprocess/preprocess-page.inc and did the form modification code inside mytheme_alpha_preprocess_page(). This also works, but sure seems ugly.

Read more
Subscribe with RSS Syndicate content