0

How to have the function calls documented in php ? I would like to have something like :

= = = =

function_name1(list of args)

description of the function

foo bar (extracted from php-doc like comments)

calls:

function_name2(list of args)

function_name3(list of args)

is called in function4 function5

= = = = = = = = = = = =

function_name2(list of args)

description of the function

foo bar (extracted from php-doc like comments)

calls:

function_name5(list of args)

is called in

function1

..

Cedric
  • 5,135
  • 11
  • 42
  • 61
  • http://stackoverflow.com/questions/3859791/php-cleanup-the-junk "Is there a utility that can trace the PHP code from the main index.php so that I can figure out what isn't being used and what is, or am I stuck doing a manual cleanup?" – Cedric Oct 05 '10 at 10:04
  • I've actually forgotten this question and ask a similar (but different) one : http://stackoverflow.com/questions/4861107/reverse-engineer-phphtml-files-not-object-oriented-ones-to-produce-a-diagram – Cedric Feb 07 '11 at 09:59

3 Answers3

2

Have a look at PhpDocumentor

Nev Stokes
  • 9,051
  • 5
  • 42
  • 44
0

Take a look at http://manual.phpdoc.org/HTMLframesConverter/DOM/default

0

The most widely used documentation standard in the PHP world is PHPDoc. It is derived from JavaDoc. A large number of IDEs support PHPDoc, which means they can automate documentation and you can gain code completion and other features from it.

Several tools exist to autogenerate documentation from PHPDoc code annotations. PHPdocumentor already mentioned elsewhere is the most prominent, but you can also use Doxygen which allows for a wider range of documentation formats

Update: phpDocumentor is quite outdated and cannot properly work with PHP5.3 code (tried closures?). There is (currently) two worthwhile alternatives to look at: DocBlox and phpDox.

albert
  • 8,285
  • 3
  • 19
  • 32
Gordon
  • 312,688
  • 75
  • 539
  • 559
  • thanks !- doxygen is very usefull, has a clear great format (however, it doesn't document calls from function located in an included file for PHP). – Cedric Feb 11 '11 at 11:45