WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am somewhat familiar with the concept of packages in Java, but I'm new to Wordpress and PHP.

In a template file such as header.php, what is happening when you include the @package notation?

 * @package MyTheme
share|improve this question
up vote 6 down vote accepted

Those are PHPDoc tags. They are entirely for code documentation purposes.

share|improve this answer
The irony is: I thought the asker knew that and wanted to know what happens when it is used. – toscho Jan 10 '13 at 17:22
@toscho, very plausible interpretation :) I waited several hours after I saw your answer, thinking it would be picked as the solution. – s_ha_dum Jan 10 '13 at 17:27

Nothing will happen. This PHPDoc tag has no special meaning in WordPress, it is not a header WordPress will parse by default. Use it to group your code internally.

get_file_data() cannot read it because that function needs a : after the identifier (here package).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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