I simply wanted to know what is the most accepted way to credit yourself and describe the overall package in (preferably) the beginning of the document so other individuals viewing the code have a reference?
I would like to know the answer because of a PHP project I am working on and I believe when it is done people will view the source code. I currently have a //
comment in the beginning but it seems lacking. I have seen people use block comments and add a @author
and so forth, is this the accepted syntax?
Thanks.
Yes, the syntax with block comments and tags like
@author
and@copyright
is standardized, it's called PHPDoc.You can find a good starting reference here.
The main advantage of using this standardized way of markup for code metadata is that you can then use standardized tools like PHPDocumentor to automatically generate documentation like this. Another is that advanced IDEs like PHPStorm can parse the docblocks to provide autocomplete and other code completion functionality, and even smart refactoring tools.