1

I've inherited a custom Drupal 7 theme with many template files. I'm sure lots of them aren't actually used by the website, and were part of the testing process.

Is there a method to list which .tpl.php files are being used in the website, or for a particular page?

  • Take a look at Theme Developer. Don't know how much a help it'll be, but possibly at least a bit. – Mołot Nov 19 '14 at 15:50
1

Just print the theme hook suggestion variable in any preprocess function in template.php

print_r($variables['theme_hook_suggestions']);

If you use the Devel module then

dpm($variables['theme_hook_suggestions']);
  • That doesn't list theme files in use. – articroll31 Nov 19 '14 at 16:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.