Plugin API Hooks
A theme should work well with WordPress plugins. Plugins add functionality by using actions and filters, which are collectively called hooks (see Plugin API for more information).
Most hooks are executed internally by WordPress, so your theme does not need special tags for them to work. However, a few hooks need to be included in your theme templates. These hooks are fired by special Template Tags:
- Goes at the end of the <head> element of a theme’s header.php template file.
- Goes at the begining of the <body> element of a theme’s header.php template file.
- Goes in footer.php, just before the closing </body> tag.
- Typically goes in the <li>Meta</li> section of a Theme’s menu or sidebar.
- Goes in comments.php directly before the file’s closing tag (</div>).
Take a look at a core theme’s templates for examples of how these hooks are used.