Setting up variables for use in a template (preprocess and process functions).
Setting up variables for use in a template (preprocess and process functions).
The main role of the preprocessor is to set up variables to be placed within the template (.tpl.php) files. From Drupal 7 they apply to templates and functions, whereas in Drupal 6 preprocess functions only apply to theming hooks implemented as templates. Plain theme functions do not interact with preprocessors.