Creating a PHPDoc

This procedure describes how to create a PHPDoc from your PHP files.

 

 

Instructions on how to complete a procedure

To create a PHPDoc:

  1. Right-click the project from which you would like the PHPDoc to be generated and select Generate PHP Doc -or- go to Project | Generate PHPDoc -or- press Alt+D.
    The PHPDoc Generation dialog will open.

PHPDoc Generation dialog 1

  1. If you have previously created PHPDoc settings which you would like to apply, mark the checkbox. To create a settings configuration, see point 8.

  2. Ensure that the required project, destination for the PHPDoc and PHP Executable are selected.

  3. Click Next.

PHPDoc Generation dialog 2

  1. Choose the style for your PHPDoc from the 'Converter Type' drop-down list. This will affect the layout and format of your PHPDoc.

  2. Select which basic options you want to apply: (Refer to the phpDoc Manual online at http://www.phpdoc.org for complete descriptions of the options.)

  • Parse @acess private and @internal

  • Generate highlighted source code

  • JavaDoc-compliant description parsing

  • PEAR package repository parsing

  • Descend into hidden directories

  1. Enter the following fields: (Refer to the phpDoc Manual online at http://www.phpdoc.org for complete descriptions of the options.)

  • Default package name

  • Default category name

  • Custom tags (if required)

  • Ignore tags (if required)

  • Examples directories path (if required)

  1. To save these settings so that they can be reused when creating new PHPDocs, mark the 'Save the settings of this PHPDoc export in an ini file" checkbox and specify where the ini file should be saved.

  2. Ensure the 'Open generated documentation in browser checkbox is marked to view your PHPDoc once created.

  3. Click Finish.
    A Running PHPDocumentor dialog will appear.

Your PHPDoc will be automatically created and will be opened in a browser.

By default, your phpdoc is created as an index.html file in a folder entitled 'docs' in the root of you Workspace. (e.g. C:\Documents and Settings\bob\Zend\workspaces\DefaultWorkspace\docs\index.html).

 

 

Related Links:
PHPDocs

Commenting PHP DocBlocks

phpDoc Comments